Which paper.js file do I use in their dist directory?
Asked Answered
D

1

6

I want to use paper.js, but there are 3 different versions of paper.js that I can't find an explanation for the differences of. Which do I use?

from paper.js' dist directory:

  • paper-core.js
  • paper-full.js
  • paper.js

There's actually a 4th, paper-node.js, but I assume that's for Node.js which I'm not using at the moment.

Dill answered 30/9, 2013 at 7:58 Comment(2)
The tutorials seem to use paper.js - I would use that...Jubbah
They don't have a minified version of itDill
C
7

As answered on the Github issues tracker already:

https://github.com/paperjs/paper.js/issues/296

  • paper.js is the same as paper-full.js
  • Use paper-full.js if you're working with PaperScript code.
  • Use paper-core.js if you just need the Paper API without the PaperScript extensions.

The reason why paper-full.js is the same as paper.js has to do partly with legacy, and partly with how paper.js is loaded in development through load.sh. You can read on it here: https://github.com/paperjs/paper.js#editing-and-running-code-during-development

Chanel answered 10/10, 2013 at 10:38 Comment(2)
Thank you for the answer. I downloaded Paper.js off your website (paperjs.org) and could not find the answer to this question without Googling it and hoping it showed up. Could you put the answer on your website so people in the future don't need to Google it? Thanks for the great library!Aggi
We've now incorporated this into the README file: github.com/paperjs/paper.js/#which-version-to-use Also, paper-node.js is going away since we now have a hybrid library that uses the same file in all supported environments.Vlissingen

© 2022 - 2024 — McMap. All rights reserved.