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

CommonJS support #3

Closed

Conversation

jakobmattsson
Copy link
Contributor

Thanks for finally writing a lib for something I keep rewriting over and over again in every project! :)

I've added support for CommonJS, used by node.js and its package manager npm. That way servers simulating browsers (for tests or other reasons) can install and run Cookies.js. Additionally, tools like browserify can be used in order to install Cookies.js in a browser in a modular way.

Since the name "cookies" is already taken for some server-side cookie-tool, I've suggested the name "client-cookies" for the module itself, but you can change it in package.json if you prefer something else.

If you're not familiar with npm already, you can publish your package by simply running "npm publish" from the Cookies-directory (after installing node.js).

Cheers!

@jakobmattsson
Copy link
Contributor Author

By the way, just realized I did not update cookies.min.js. Just a heads up.

@ScottHamper
Copy link
Owner

Thanks, Jakob!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants