glideapps / glide-data-grid

🚀 Glide Data Grid is a no compromise, outrageously react fast data grid with rich rendering, first class accessibility, and full TypeScript support.
https://grid.glideapps.com
MIT License
3.99k stars 288 forks source link

Warnings from Rollup - cannot interpret *#__PURE__* due to position of the comment #975

Open rfdrake27 opened 3 months ago

rfdrake27 commented 3 months ago

Now when building with vite, I see many warnings like this:

node_modules/@glideapps/glide-data-grid/dist/esm/internal/data-grid-overlay-editor/data-grid-overlay-editor-style.js (3:14): A comment

"/*#__PURE__*/"

in "node_modules/@glideapps/glide-data-grid/dist/esm/internal/data-grid-overlay-editor/data-grid-overlay-editor-style.js" contains an annotation that Rollup cannot interpret due to the position of the comment. The comment will be removed to avoid issues.
node_modules/@glideapps/glide-data-grid/dist/esm/internal/data-grid-overlay-editor/data-grid-overlay-editor-style.js (4:14): A comment

"/*#__PURE__*/"

I'm on version 6.0.3

citizensas commented 3 months ago

I guess the reason behind this is because of how the pure annotation requires a white between itself and the following script.
In this example you can see that it should've been a space right before the styled method.

- const ScrollRegionStyle = /*#__PURE__*/styled('div')
+ const ScrollRegionStyle = /*#__PURE__*/ styled('div')

I don't know whether this is a bug in Linaria or another dependent package.