Coder Social home page Coder Social logo

AMD support about phaser HOT 5 CLOSED

phaserjs avatar phaserjs commented on May 23, 2024
AMD support

from phaser.

Comments (5)

photonstorm avatar photonstorm commented on May 23, 2024

Do you mean being able to build your game using requireJS/etc, or moving the framework to use modules?

from phaser.

hlfcoding avatar hlfcoding commented on May 23, 2024

Both would be nice. Having initial AMD support would be more important. I'm not sure how interdependent the Phaser classes are, so splitting into modules may not need to happen, esp. if this is going onto a CDN in the future. Also, I can just require.config() and set a shim for Phaser, which is what I'm doing now, so AMD support isn't required for me, and you can close as seen fit.

from phaser.

HackManiac avatar HackManiac commented on May 23, 2024

I'm using the shim way at the moment as well. Having the possibility to load Phaser without the shim workaround would be appreciated, perhaps by using another grunt copy task to wrap the generated JavaScript in an UMD wrapper. No need to convert Phaser to use a module system itself from my side. It works beatifully the way it is now!

from phaser.

photonstorm avatar photonstorm commented on May 23, 2024

As it stands now none of the Phaser classes are independent (by design choice), but I could see a need for that once I introduce plugin support. As long as you can actually make a game using AMD your end and it's not blocking you in any way, then I'm happy with that. If someone wants to contribute additional grunt tasks/etc to make workflow easier for you then please do so.

from phaser.

photonstorm avatar photonstorm commented on May 23, 2024

This is now resolved in 0.9.4 thanks to HackManiac's updated grunt file.

from phaser.

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.