|
il y a 5 ans | |
---|---|---|
.config | il y a 5 ans | |
.github | il y a 5 ans | |
bench | il y a 5 ans | |
playgrounds | il y a 5 ans | |
spec | il y a 5 ans | |
src | il y a 5 ans | |
.eslintrc.yaml | il y a 5 ans | |
.gitignore | il y a 5 ans | |
.travis.yml | il y a 5 ans | |
CHANGELOG.md | il y a 5 ans | |
LICENSE.txt | il y a 5 ans | |
README.md | il y a 5 ans | |
package-lock.json | il y a 5 ans | |
package.json | il y a 5 ans | |
svg.js.d.ts | il y a 5 ans |
A lightweight library for manipulating and animating SVG, without any dependencies.
SVG.js is licensed under the terms of the MIT License.
npm install svg.js
yarn add svg.js
bower install svg.js
https://cdnjs.com/libraries/svg.js
Check svgjs.com to learn more.
To develop svg.js, you have a few commands available to you. Firstly, you should clone this repo, then cd into the folder with this README and run:
npm install
You’ll now have all the dev dependencies installed, and you’ll be ready to build the bundle. Once you’ve made your changes just run:
npm run build
This will build svg.js and make a distribution in the /dist
folder. While developing, this may not be so convenient as the build will fail if you have any linting errors, refer to the standard coding styleguide for style we use, linters are available for most popular text editors as well.
This will set up everything. While you are working, you should make sure your changes pass all of our tests, so just run:
npm run test
Or just launch the jasmine test runner from /spec/SpecRunner.html
. Its good to try the spec runner on a few different browsers.
You can run performance tests by making a new benchmarks, look in the /bench
folder and just add a new js file with the test you want to make. We include a few examples in the repo to make it easy for you to make your own.
If you would like a simple sandbox that you can use, take a look into the sandbox folder.
We welcome any pull requests and will try our hardest to review them as soon as possible. If you need any help or would like to chat, check out our gitter group, we are always happy to see new users!