Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

2.0.0 #36

Merged
merged 16 commits into from
Apr 21, 2024
Merged

2.0.0 #36

merged 16 commits into from
Apr 21, 2024

Conversation

amorey
Copy link
Member

@amorey amorey commented Apr 21, 2024

This pull request implements a new major version of Edge-CSRF (2.0.0) with several breaking changes:

  • Splits functionality into three separate public packages:
    • @edge-csrf/nextjs - Next.js integration library
    • @edge-csrf/sveltekit - SvelteKit integration library
    • @edge-csrf/core - Core API
  • The integration libraries each offer high-level and low-level integration methods:
    • A method for creating drop-in middleware (e.g. createCsrfMiddleware(), createCsrfHandle())
    • A method for creating functions that can be used inside middleware (e.g. createCsrfProtect())
  • Internally the code was re-organized into a monorepo structure with three public packages and a private package for shared code using pnpm workspaces for management
  • It should be easy to add new framework integrations with the new repo structure

amorey added 16 commits April 17, 2024 17:06
* Refactored code internally to add support for multiple frameworks
* Added sveltekit integration
* Exposed lower-level api
* Added more unit tests
* removed unnecessary dependencies
* fixed exports in package.json
* fixed error export
* next14 and sveltekit examples are working
* added types to package.json, moved peerDependencies to optionalDependencies
* fixed build externals issue
* updated examples
* fixed linting issue
* updated pnpm-lock.yaml
* wip

* wip

* renamed vars
@amorey amorey merged commit 0d7007b into main Apr 21, 2024
3 checks passed
@amorey amorey deleted the 2.0.0-monorepo branch April 21, 2024 04:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant