dan-cooke / remix-sse

Server Sent Events (SSE) for the remix framework
Apache License 2.0
78 stars 3 forks source link

Break package into 2 seperate packages #17

Closed dan-cooke closed 8 months ago

dan-cooke commented 8 months ago

Motivation

Exporting both the client and server code from a single package has never sat well with me, at the start I got by releasing a single package: remix-sse for server code and remix-sse/client for client code.

This works fine if you are trasnpiling CommonJS imports, but at some point recently create-remix has started every project with type: "module" (ES Modules).

So this made our import paths quite ugly

remix-sse/client/index.js - because ES modules have 2 restrictions

  1. You can no longer do directory imports
  2. It does not assume the file extension

Not to mention this uglier syntax was less discoverable now by language servers.

Solution

The package will now be split up into 2 packages

changeset-bot[bot] commented 8 months ago

🦋 Changeset detected

Latest commit: 2a59f03c4e3deabbdb7af28d8641479565b990e4

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 2 packages | Name | Type | | ----------------- | ----- | | @remix-sse/client | Major | | @remix-sse/server | Major |

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR