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

Two semicolon in property crash minify #378

Open
zoobestik opened this Issue Apr 17, 2018 · 1 comment

Comments

Projects
None yet
3 participants
@zoobestik
Contributor

zoobestik commented Apr 17, 2018

Two semicolon in css file breaks minify. For ex.:

.c .d { color: #ffffff;; }

Throw the error:

Cannot read property '0' of undefined TypeError: Cannot read property '0' of undefined
    at getPropertyDescriptor (.../css-tree/lib/utils/names.js:65:24)
    at getPropertyFingerprint (.../csso/lib/restructure/6-restructBlock.js:68:20)
    at List.<anonymous> (.../csso/lib/restructure/6-restructBlock.js:213:27)
    at List.eachRight (.../css-tree/lib/utils/list.js:182:12)
    at Object.processRule (.../csso/lib/restructure/6-restructBlock.js:211:18)

screen shot 2018-04-17 at 12 26 40

screen shot 2018-04-17 at 12 29 46

@Avol-V

This comment has been minimized.

Avol-V commented Jun 16, 2018

I have the same issue:

TypeError: Cannot read property '0' of undefined
    at getPropertyDescriptor (node_modules/css-tree/lib/utils/names.js:65:24)
    at getPropertyFingerprint (node_modules/csso/lib/restructure/6-restructBlock.js:68:20)
    at List.<anonymous> (node_modules/csso/lib/restructure/6-restructBlock.js:213:27)

In 6-restructBlock.js declaration is:

{
	fingerprint:null,
	id:211,
	length:1,
	loc:null,
	type:"Raw",
	value:";",
}

So declaration.property is undefined.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment