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

Make more compatible for browser use. Pass TypeScript checks #51

Closed
AckerApple opened this issue Jun 14, 2018 · 8 comments
Closed

Make more compatible for browser use. Pass TypeScript checks #51

AckerApple opened this issue Jun 14, 2018 · 8 comments
Assignees

Comments

@AckerApple
Copy link
Collaborator

When compiling code for updated versions of TypeScript, it now checks the require statements and several errors are being thrown:

ERROR in ../node_modules/jsonexport/dist/core/join-rows.js
Module not found: Error: Can't resolve 'os'
ERROR in ../node_modules/jsonexport/dist/parser/csv.js
Module not found: Error: Can't resolve 'os'
ERROR in ../node_modules/jsonexport/dist/core/stream.js
Module not found: Error: Can't resolve 'stream'
ERROR in ../node_modules/jsonexport/dist/parser/csv.js
Module not found: Error: Can't resolve 'stream'

It seems require('stream') and require('os') are not even really needed for the browser. The EOL can just be backslash "\n" in the browser. And stream is not needed if a callback is provided.

I manually edited the node_modules/jsonexport files and all came out well and built to browser. I will need to find the most compatible way to have all files live in harmony and that the dist folder has NO node based requires.

Will have to complete this with-in a weeks time at max. Please be available to publish to npm when I have completed

@AckerApple AckerApple self-assigned this Jun 14, 2018
@kaue
Copy link
Owner

kaue commented Jun 14, 2018

I will be avaliable for the publish, but i already added you as a collaborator so you should be able to publish also

@AckerApple
Copy link
Collaborator Author

AckerApple commented Jun 14, 2018

Please check out my push when you get a chance.

Commit link here

Change log


  • v2.2.0 - Better browser distribution
    • Browser based files in dist are overwritten for best browser building
    • Found unused code and removed
    • Updated all depencies
      • Some had minor version changes
      • This package now changes its minor from 2.1 to 2.2
      • Added npm-run-all to safely run npm multi commands across all operating systems

@AckerApple
Copy link
Collaborator Author

I'm going to try and publish this code to npm. I feel real confident of it and in need of it for my team.

@kaue
Copy link
Owner

kaue commented Jun 15, 2018

@AckerApple go for it!

@AckerApple
Copy link
Collaborator Author

Published. I really am humbled and extra appreciative of being entrusted to maintain and publish this package. Quite the honor.

@kaue
Copy link
Owner

kaue commented Jun 15, 2018

@AckerApple I am honoured to have you helping maintaining this package!
Really, thanks Acker!

@AckerApple
Copy link
Collaborator Author

Would be cool to cross your path someday. Your github icon is soulfully great to see, zoomed in to see you got a smile. Little things, the little things.

@kaue
Copy link
Owner

kaue commented Jun 15, 2018

Yes, i want to meet you too! send me an email (check my gh profile) with your skype, whatsapp or telegram info =)

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

No branches or pull requests

2 participants