GithubHelp home page GithubHelp logo

netteForms.js: common js, amd about forms HOT 5 CLOSED

nette avatar nette commented on July 3, 2024
netteForms.js: common js, amd

from forms.

Comments (5)

JanTvrdik avatar JanTvrdik commented on July 3, 2024

netteForms.js must be able to work without common js or amd environment

from forms.

vojtech-dobes avatar vojtech-dobes commented on July 3, 2024

common js / amd compatibility should be achievable without dependency on anything, I think.

from forms.

davidkudera avatar davidkudera commented on July 3, 2024

@JanTvrdik I know and that is why I send link to nprogress, which works great in each environment and without any dependency.

Actually I had to (temporary) create custom transform function for browserify which will wrap netteForms.js into function like that:

(function() {
    var Nette = Nette || {};

    // ...

    module.exports = Nette;
});

Edit:

Of course this code is just for common js

from forms.

davidkudera avatar davidkudera commented on July 3, 2024

The only thing I would do differently from nprogress is line 14, where I would use window instead of this. Thats because for example browserify wraps each module (file) in another function with different scope

Edit:

It really doesn't matter.... If I'm using browserify, than I don't need any window.. Sorry for useless comment

from forms.

davidkudera avatar davidkudera commented on July 3, 2024

Thank you sir

Dne so, 14. 3. 2015 17:53 uživatel David Grudl [email protected]
napsal:

Closed #69 #69 via 6f27810
6f27810
.


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

from forms.

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.