-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Isomorphic #25
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
Comments
The idea of the library supporting node have been on my mind for a while. It would be great to merge your work! I will probably have to review the changes another day as I don't have the time right now but will comment on the changes then. |
Sounds good @lindell, I'll will finish up the packaging and server side canvas stuff likely today. Feel free to comment whenever you have time. |
@lindell I've added all the packaging and canvas support. It turns out to be most flexible to just return the canvas object for both server and client, at that point you can stream it to a file or render it to an image depending what side you are using the lib on, the readme reflects the updated api and examples.
|
I'm sorry I have not taken a look at this yet. I'm in the end of my period and have my exams next week. Will check the code and then merge it after next week. |
Hello. First I want to say sorry for completely ignoring this for so long. I did almost competently quit github for almost a year except for fixing a few bugs. When I started updating JsBarcode again a few months back and looked at this issue I looked at your code and saw you where using ES6 syntax and thought it was no way it was still running in the browser without realizing you where using babel and webpack to compile it. I think it was well needed change and I'm changing to that now. Unfortunately it would be to much of an hassle to fork the changes but I will take a lot of inspirations. I'm right now working on a big change with a change in the API which will make me upgrade to version 3 of the library. I will then add a contributors chapter in the readme and add you there. |
I did also add nodejs support a while back. Therefore closing the issue |
@lindell First, thanks for the hard work on this library, it appreciated!
So, I had a need for a barcode generator to:
Your library was the furthest along from what I found. I also scratched an itch with ES6 and webpack for bundling. The result so far is this:
https://github.com/wavded/JsBarcode/tree/isomorphic
I still have to integrate
node-canvas
for server side data URI generation and packaging but I tried hard to ensure none of the core logic was lost. Here is my test page against your test generator app examples:My question is, do you have any interest in merging this in? Of course with your feedback. I will happily maintain a fork for my purposes but like the idea of having this project continue to receive bug fixes and improvements in one spot than make yet another barcode generator. There are some notable and breaking changes which are up for discussion but here is my rationale:
data-uri
for consistency server and client.JsBarcode
, e.g.JsBarcode.CODE39(content)
. I'm not married to that but seemed clearer at the time.Thoughts?
The text was updated successfully, but these errors were encountered: