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

Refactor More Parsing Logic into Subparsers #4

Open
jnterry opened this issue Apr 24, 2020 · 0 comments
Open

Refactor More Parsing Logic into Subparsers #4

jnterry opened this issue Apr 24, 2020 · 0 comments
Labels
enhancement New feature or request

Comments

@jnterry
Copy link
Member

jnterry commented Apr 24, 2020

The main parser.ts file is getting very big and complicated.

We've split out parsing for footnote and cross reference environments into their own files - but its becoming clear that we are needing to duplicate code in these and the main parser file (eg, for generic text styling markersv (https://ubsicap.github.io/usfm/characters/index.html#special-text)

It would probably be possible to make the code more readable (and also remove duplication) by refactoring these "subparsers" into a resuable modular system, then each parser could be made up of multiple subparsers that can be combined depending on what symbols are allowed in a given environment.

@jnterry jnterry added the enhancement New feature or request label Apr 24, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant