Coder Social home page Coder Social logo

Comments (10)

savelichalex avatar savelichalex commented on June 26, 2024

This is becouse if you want then package will be transpiled in node_modules folder package must have in package json this:
"browserify": {
"transform": ["babelify"]
}

from js-csp.

niwinz avatar niwinz commented on June 26, 2024

Is just that I have said that does not works.

from js-csp.

savelichalex avatar savelichalex commented on June 26, 2024

Let me have you look into your code. Or write example how you use browserify

from js-csp.

niwinz avatar niwinz commented on June 26, 2024

This is a part of gulpfile that we are using for build our project https://gist.github.com/niwinz/671a8d53a510e0d05db7. We are using the latest versions of babel and browserify.

And, independently of "browserify": {"transform"... in the project.json, browserify includes in bundle not babelified files of js-csp. At this moment I have a workaround having js-csp directly in source (under "vendor" directory) until I will be able solve this issue.

from js-csp.

savelichalex avatar savelichalex commented on June 26, 2024

Andrey, please show me your project.json file. I'm sure that you wrong
understand where browserify instructions must be. You should open
node_modules folder, then js-csp and in this folder in package.json add
broserify instructions to transfowm with babelify

On Mon, Oct 12, 2015 at 10:34 AM, Andrey Antukh [email protected]
wrote:

This is a part of gulpfile that we are using for build our project
https://gist.github.com/niwinz/671a8d53a510e0d05db7. We are using the
latest versions of babel and browserify.

And, independently of "browserify": {"transform"... in the project.json,
browserify includes in bundle not babelified files of js-csp. At this
moment I have a workaround having js-csp directly in source (under "vendor"
directory) until I will be able solve this issue.


Reply to this email directly or view it on GitHub
#68 (comment).

from js-csp.

savelichalex avatar savelichalex commented on June 26, 2024

https://github.com/ubolonton/js-csp/pull/45/files

On Mon, Oct 12, 2015 at 11:04 AM, Лёша Савельев [email protected]
wrote:

Andrey, please show me your project.json file. I'm sure that you wrong
understand where browserify instructions must be. You should open
node_modules folder, then js-csp and in this folder in package.json add
broserify instructions to transfowm with babelify

On Mon, Oct 12, 2015 at 10:34 AM, Andrey Antukh [email protected]
wrote:

This is a part of gulpfile that we are using for build our project
https://gist.github.com/niwinz/671a8d53a510e0d05db7. We are using the
latest versions of babel and browserify.

And, independently of "browserify": {"transform"... in the project.json,
browserify includes in bundle not babelified files of js-csp. At this
moment I have a workaround having js-csp directly in source (under "vendor"
directory) until I will be able solve this issue.


Reply to this email directly or view it on GitHub
#68 (comment).

from js-csp.

niwinz avatar niwinz commented on June 26, 2024

I have updated the gist with package.json.

In any case, my package.json has the exact thing that the babelify readme suggest: "Add to the root of all your modules package.json that you want to be transformed."

Adding "browserify": {"transform"... to the package.json of the js-csp on node modules is not an option, because is fully error prone and implies that every team member should do that tweaks. The current solution of having the js-csp in our repositorio works much better, because all team member does not need special tweaks on vendor related package.json...

from js-csp.

savelichalex avatar savelichalex commented on June 26, 2024

I think that only solutions described by @nmn in his PR can help you. In
our company we choose webpack instead browserify + babelify that perfectly
solves this problem. But you can try to work with viralify or apply
transform globally

On Mon, Oct 12, 2015 at 11:27 AM, Andrey Antukh [email protected]
wrote:

I have updated the gist with package.json.

In any case, my package.json has the exact thing that the babelify readme
suggest: "Add to the root of all your modules package.json that you want to
be transformed."

Adding "browserify": {"transform"... to the package.json of the js-csp on
node modules is not an option, because is fully error prone and implies
that every team should do it. The current solution of having the js-csp in
our repositorio works much better, because all team member does not need
special tweaks on vendor related package.json...


Reply to this email directly or view it on GitHub
#68 (comment).

from js-csp.

ashnur avatar ashnur commented on June 26, 2024

I am using js-csp with babel just with cli arguments, no package.json setting or .babelrc:

browserify -t [ babelify --presets [ es2015 ] --plugins [ transform-runtime ] ]  src/index.js -o js/bundle.js

This works 100% :)

from js-csp.

hung-phan avatar hung-phan commented on June 26, 2024

Closed this now. You don't need to apply transform to js-csp any more. It is already done for you.

from js-csp.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.