acorn icon indicating copy to clipboard operation
acorn copied to clipboard

Acorn We applet

Open weswalla opened this issue 2 years ago • 6 comments

todo

  • [ ] make CSS bundle and be injected in one build process (I believe currently both index.js and cssBundle.css are built in the same step, but index.js should be dependent on cssBundle.css being built first)
  • [ ] create project meta on applet install only (make unique for access purposes)
  • [ ] handle project joining
  • [ ] fix map view performance issues
  • [ ] bundle fonts into applet package

weswalla avatar Nov 02 '22 16:11 weswalla

We are currently pausing this PR until React has been updated to 17/18. The reason being is that events inside react components were not registering within the shadow DOM. According to https://github.com/facebook/react/issues/10422 this is not an issue with React 17+

weswalla avatar Nov 04 '22 23:11 weswalla

with the successful bump of the react version and events working inside the shadow DOM, it seems that the remaining big issues are to do with CSS and imported assets (fonts, images, etc)

weswalla avatar Nov 05 '22 03:11 weswalla

ok great. as we've seen some of the CSS operational, it seems clear we can fix it. Re. the imported assets, I am more confident about images than fonts. We should be able to instruct webpack to deliver the image assets as base64 encoded strings, inline, instead of being an image asset served at an endpoint.

Connoropolous avatar Nov 07 '22 17:11 Connoropolous

ok great. as we've seen some of the CSS operational, it seems clear we can fix it. Re. the imported assets, I am more confident about images than fonts. We should be able to instruct webpack to deliver the image assets as base64 encoded strings, inline, instead of being an image asset served at an endpoint.

I believe that "inlining assets" is essentially the path https://webpack.js.org/guides/asset-modules/#inlining-assets

Connoropolous avatar Nov 07 '22 17:11 Connoropolous

Screenshot 2022-11-07 at 9 58 10 AM

I mentioned base64 encoded strings, and this is the same thing: "data URI" (see https://en.wikipedia.org/wiki/Data_URI_scheme)

Connoropolous avatar Nov 07 '22 18:11 Connoropolous

maybe condense the two PRs down into just one at this point? You can edit the "base" branch so that it gives a comparison against main

Connoropolous avatar Dec 27 '22 18:12 Connoropolous