webref icon indicating copy to clipboard operation
webref copied to clipboard

NPM package not up to date with release?

Open pyoor opened this issue 3 years ago • 3 comments

It appears that the npm package is not up to date with the source tree. I'm not sure if this is expected or a bug:

Files ~/webref/ed/css/css-color.json and node_modules/@webref/css/css-color.json differ
Files ~/webref/ed/css/css-contain-3.json and node_modules/@webref/css/css-contain-3.json differ
Files ~/webref/ed/css/css-easing.json and node_modules/@webref/css/css-easing.json differ
Files ~/webref/ed/css/css-flexbox.json and node_modules/@webref/css/css-flexbox.json differ
Files ~/webref/ed/css/css-fonts.json and node_modules/@webref/css/css-fonts.json differ
Files ~/webref/ed/css/css-gcpm.json and node_modules/@webref/css/css-gcpm.json differ
Files ~/webref/ed/css/CSS.json and node_modules/@webref/css/CSS.json differ
Files ~/webref/ed/css/css-logical.json and node_modules/@webref/css/css-logical.json differ
Files ~/webref/ed/css/css-overflow.json and node_modules/@webref/css/css-overflow.json differ
Files ~/webref/ed/css/css-position.json and node_modules/@webref/css/css-position.json differ
Files ~/webref/ed/css/css-round-display.json and node_modules/@webref/css/css-round-display.json differ
Files ~/webref/ed/css/css-text-decor-4.json and node_modules/@webref/css/css-text-decor-4.json differ
Files ~/webref/ed/css/css-ui.json and node_modules/@webref/css/css-ui.json differ
Files ~/webref/ed/css/css-values.json and node_modules/@webref/css/css-values.json differ
Files ~/webref/ed/css/fill-stroke.json and node_modules/@webref/css/fill-stroke.json differ
Files ~/webref/ed/css/SVG.json and node_modules/@webref/css/SVG.json differ
Files ~/webref/ed/css/svg-strokes.json and node_modules/@webref/css/svg-strokes.json differ

pyoor avatar Sep 07 '22 17:09 pyoor

It depends... Which source tree are you looking at?

The npm package should be up to date with the webref/css@latest branch. Is that not the case?

The webref/css@latest branch is a snapshot of the curated branch at the time when the NPM package is released. The curated branch is in turn derived from the main branch.

This should be more explicitly explained in the README. The only mention of the @latest branches is in the releases to NPM section

tidoust avatar Sep 07 '22 18:09 tidoust

@tidoust I didn't realize it was a snapshot of https://github.com/w3c/webref/tree/curated. Are the patches applied to that branch available somewhere? I'm curious why several of the SVG-2 properties have been removed from the spec.

Also, would you ever consider publishing the "uncurated" results under a separate tag?

pyoor avatar Sep 07 '22 18:09 pyoor

Yes, the curation logic is in the repo. For CSS extracts, the curation logic takes the form of CSS patches (but that's not what explains SVG2 removals) and a specific drop-css-property-duplicates.js script to remove duplicate definitions.

We already track the "uncurated" results, although indirectly. You just need to look at the commits of the webref/css@latest branch. Last one currently is https://github.com/w3c/webref/commit/5b442b01203e17f1190918f5ed89af99dbe799cf and says that it got generated from https://github.com/w3c/webref/commit/d78320b6a7e498674c1b8c80b42bbe3b82cdff0a on the main branch.

tidoust avatar Sep 09 '22 17:09 tidoust