jorgegorka / svelte-router

Svelte Router adds routing to your Svelte apps. It's designed for Single Page Applications (SPA). Includes localisation, guards and nested layouts.
MIT License
509 stars 42 forks source link

refactor!: refactor the whole code base to esm #106

Closed si3nloong closed 3 years ago

si3nloong commented 3 years ago

Latest bundling tool such as snowpack or vite are expecting package in esm format. When we are using cjs format, likely to hit error when running with those tool. What I amended on the package mainly are :

si3nloong commented 3 years ago

Hi! Great job you have done here. Does this fix the module exporting issue? Are the types and functions defined? I was planning on working on this but it seems that you have done a good job rewriting it the correct way!

It should fix the module exporting issue, since i ady added an module keyword to package.json. I have yet to work on the typescript type. If there is necessary, will complete it within this week.

moalamri commented 3 years ago

Well done :)

jorgegorka commented 3 years ago

Hi @si3nloong

Thank you very much for your PR. Let me review it this weekend.

Thanks again.

moalamri commented 3 years ago

You have done a lot of work :) Thank you for sparing your time making this package more awesome

jorgegorka commented 3 years ago

Hi @si3nloong

I've merged your PR in a branch called version-6.