Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unified Token Formatting and Rendering #364

Merged
merged 2 commits into from
Nov 24, 2021
Merged

Conversation

nfrasser
Copy link
Owner

@nfrasser nfrasser commented Nov 23, 2021

This will allow for more cohesive formatting in Linkify's core methods, simpler interface implementations and consistent options across interfaces.

  • New MultiToken#toFormatted*() methods that accept options
  • New MultiToken#render() method to return tag intermediate representation for final HTML
  • New Options implementation to support token rendering
  • Removed Options#resolve() method in favour of Options#render()
  • All Interfaces updated accordingly

Fixes #357
Fixes #349

@nfrasser nfrasser self-assigned this Nov 23, 2021
Nick Frasser added 2 commits November 23, 2021 19:06
- New toFormatted* token methods that accept options
- New render() token method to return final HTML tag intermediate
  representation
- New Options implementation to support token rendering
= Removed Options#resolve() method in favour of render

Still need to update the interfaces to take advantage of this new
paradigm
@nfrasser nfrasser force-pushed the unified-token-rendering branch from 7587c27 to 33f8657 Compare November 24, 2021 00:06
@nfrasser nfrasser marked this pull request as ready for review November 24, 2021 00:06
@nfrasser nfrasser merged commit fc2e7d0 into v4.0 Nov 24, 2021
@nfrasser nfrasser deleted the unified-token-rendering branch November 24, 2021 00:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant