-
Notifications
You must be signed in to change notification settings - Fork 40
Separate test runner and other imrovements #57
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
base: main
Are you sure you want to change the base?
Conversation
b84d3ff
to
4ebbcc5
Compare
Nope, it's purely been a matter of me not having the time to review them. |
- Separate the test runner script to a new test.js file so that the developers of other projects can import and run the test cases on their own.
- This prevents the parseerror message show "0x-1". - There is no \x00, which has been replaced during preprocessing, in the input codepoints.
- Wrap internal variables in a closure to prevent repeated instantiation when called. - Define every internal function using a direct function expression rather than an anonymous function.
Rebased on top of #59. |
@tabatkins I'm wondering if there's still any plan to continue development on this parser. Since it has been halted for over a year. As a developer, I’m in need of a spec-compliant CSS parser that can safely handle CSS rewriting, especially in edge cases. Ideally, I’d like to use an existing, well-maintained parser rather than building one from scratch. I've tried several popular parsing libraries like That said, I’ve noticed some limitations in this project that may make it less suitable for my use case:
I'd really appreciate your thoughts on both points. The second one seems fairly easy to implement if you're in agreement. The first may require more discussion and design considerations. If this project isn’t intended to support such extended use cases, I may need to fork it or build something custom. That said, I hope the spec can evolve in a way that accommodates these types of real-world usage scenarios (e.g., by allowing comment tokens or preserving source information). Otherwise, developers may be forced to rely on non-spec-compliant parsers, which undermines the goal of having a shared, universal standard. |
As explained in the commit messages.