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

Use maxBytes from Spec instead of hard-coding it #231

Merged
merged 5 commits into from Jun 6, 2021

Conversation

schlessera
Copy link
Collaborator

We had initially hard-coded the maxBytes spec value for enforcing the byte limit on CSS.

This PR changes the code to use the spec value directly instead.

Note that the hard-coded value was already stale, so this also fixes a bug.

@schlessera schlessera added Bug Something isn't working DOM Optimizer labels Jun 6, 2021
@schlessera schlessera added this to the 0.6.0 milestone Jun 6, 2021
src/Dom/Document.php Outdated Show resolved Hide resolved
src/Dom/Document.php Outdated Show resolved Hide resolved
src/Dom/Document.php Outdated Show resolved Hide resolved
tests/Dom/DocumentTest.php Outdated Show resolved Hide resolved
tests/Dom/DocumentTest.php Outdated Show resolved Hide resolved
tests/Dom/DocumentTest.php Outdated Show resolved Hide resolved
tests/Dom/DocumentTest.php Outdated Show resolved Hide resolved
tests/Dom/ElementTest.php Outdated Show resolved Hide resolved
tests/Dom/ElementTest.php Outdated Show resolved Hide resolved
tests/Dom/ElementTest.php Outdated Show resolved Hide resolved
@schlessera
Copy link
Collaborator Author

I also moved the TransformedIdentifier to be the very first transformer now. Given that we have special validation rules for transformed VS non-transformed, I think it makes sense to set that attribute as soon as possible.

@schlessera schlessera merged commit b3bb93a into main Jun 6, 2021
@schlessera schlessera deleted the fix/use-max-bytes-from-spec branch June 6, 2021 19:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug Something isn't working DOM Optimizer
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants