Giter Club home page Giter Club logo

#Building the KineticJS Framework To build the framework, you need to have node installed. After that, run npm install in the main directory to install the node module dependencies.

To build a development version of the framework, run grunt dev. To run a full build, which also produces the minified version and the individually minified modules for the custom build, run grunt full. You can also run grunt beta to generate a beta version.

If you add a file in the src directory, be sure to add the filename to the sourceFiles array variable in Gruntfile.js.

#Testing

Getting the tests up and running

Currently, KineticJS has unit, functional, visual, manual, performance, and special test suites. Open tests/html/index.html to run each test suite. Before running any of the tests, be sure to build a dev version first with grunt dev. To build the unit tests, you'll need to build the unitTests.js file by running grunt test and then opening unitTests.html.

Running the tests

Unit, functional, and performance tests output the results to the console via console.log() so be sure to have it open.

In order for the data url tests and image manipulation tests to pass, you need to run the unit test suite on a web server due to canvas security constraints (read more about that here). All tests should pass in Google Chrome on Windows 7 with no warnings, and all tests should pass with some warnings in other browsers and operating systems.

Updating the tests

To add / modify unit tests, be sure to do so in the tests/js/unit directory, because these are the source test files that are concatenated together when building unitTests.js. Use test() for hard tests which will throw an error if something fails, and use warn() for soft tests that will allow the tests to continue if the test condition fails. The warn() method is great for tests that will have different results in different browsers, such as canvas data url comparisons, text metric dimensions, etc.

TIP: prepend a test name with a * to only run that particular test, or prepend a test name with ! to omit that test.

#Pull Requests I'd be happy to review any pull requests that may better the KineticJS project, in particular if you have a bug fix, enhancement, or a new shape (see src/shapes for examples). Before doing so, please first make sure that all of the unit tests and functional tests pass, and also make sure that you don't have any jshint errors. You can do so by running grunt hint

Diana Pazheva's Projects

openui5 icon openui5

OpenUI5 lets you build enterprise-ready web applications, responsive to all devices. running on almost any browser of your choice

ui5-inspector icon ui5-inspector

With the UI5 Inspector, you can easily debug and support your OpenUI5/SAPUI5 based apps.

ui5-webcomponents icon ui5-webcomponents

UI5 Web Components - the enterprise-flavored sugar on top of native APIs! Build SAP Fiori user interfaces with the technology of your choice.

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.