hdresearch / nolita

Work with web-enabled agents quickly — whether running a quick task or bootstrapping a full-stack product.
https://nolita.ai
MIT License
90 stars 6 forks source link

pkg: esm migration #123

Closed matildepark closed 2 months ago

matildepark commented 3 months ago

Let's hold this and really test it.

~npm run serve runs~ it runs until you try to open a new page. ~nolita task runner functions normally~ unless it needs to go to a new page. Need to try other critical paths.

Would definitely necessitate a breaking change bump to 3.0 since CJS would then be deprecated. Need to try importing the package in create and in a non-create package, probably.

matildepark commented 3 months ago

Right, I think jest needs a specific flag.

edit: Apparently our jest doesn't use the same TSConfig as the rest of the codebase? It chokes up at a module resolution that we're already set and compile with. I wonder if it makes more sense to be compiling and testing the compiled code vs. testing the source? Not sure.

matildepark commented 3 months ago

Hmm, I think navigation is broken on this branch. But if you go right to a page it works. Need to try re-resolving types in the imports I think, instead of referencing .js files without them.