This library contains the Platypi framework, PlatypusTS. It serves as the basis for many of the other Platypi products.
None, PlatypusTS is meant to ship with no dependencies.
While developing, ensure that NodeJS is installed.
PlatypusTS is designed for use in a browser only. It works in all modern browsers (IE >= 9)
Find all the documentation on PlatypusTS here
To build the code take the following steps:
- From the root project folder run:
npm install
- Run the following task:
npm run build-all
To build a deployment package of PlatypusTS take the following steps:
- Ensure that Grunt is installed. If you need to install it you can use the following command:
npm install grunt -g
- Run the following command:
grunt
- You will find the compiled package in the
dist
directory.
PlatypusTS is heavily documented using JSDoc format. However, for distribution many of the comments are stripped out in order to make them easier to read in various IDEs. To get a build of the framework with full documentation take the following steps:
- Ensure that Grunt is installed. If you need to install it you can use the following command:
npm install grunt -g
- Run the following command:
grunt docs
- You will find the compiled package in the
dist
directory.
While developing the code, there are a few useful npm scripts:
watch-examples
: Builds and watches the examples directorywatch-src
: Builds and watches the src directorywatch-test
: Builds and watches the test directory
Run any of these scripts with the following command:
npm run <script>
The examples directory is a playground for quickly testing functionality. You can run the examples using the following command:
npm run examples
This will open a server in the examples
directory running on port 3000. You can then open you browser to http://localhost:3000 to
use the examples.
To run the unit tests for PlatypusTS take the following steps:
- Ensure that NodeJS is installed.
- Ensure that Karma CLI is installed. If you need to install it you can use the following command:
npm install karma-cli -g
- Run the following command:
npm test
When you run tests they output code coverage. You can find the code coverage files in the test/coverage
directory.
To clean all the built-files execute the following command:
npm run clean-all
NOTE: More tasks can be found in the
package.json