Coder Social home page Coder Social logo

amber-graphical-libraries-demo's People

Contributors

hhzl avatar

Stargazers

 avatar  avatar

Watchers

 avatar  avatar  avatar

Forkers

tariqhamid

amber-graphical-libraries-demo's Issues

Too much recursion in JSProxyObject

Class Paper2 has a newPath method which gives back an instance of a JSProxyObject. However when I send a message to that object I get an error *too much recursion.

!Paper2 class methodsFor: 'not yet classified'!

newPath
<return (new paper.Path());>
!

main
| canvas aPath |
   canvas := document getElementById: 'myCanvas'.

   "Create an empty project and a view for the canvas:" 
    paper setup: canvas.

    aPath := self newPath.

"Give the stroke a color"
aPath inspect.
aPath strokeColor: 'red'.
!

Note Class Paper1 is a JavaScript only solution which works. The aim of class Paper2 is to have it translated into Smalltalk.

Fix bower.json

In #2 the installation instructions were updated. Now bower.json has to reflect this.

Inclusion of paperjs

Is the way used to include the in index.html correct?

 <script type='text/javascript'>
  require.config({ paths: {
    'paper': 'bower_components/paper/dist'
  }});
  require([
           'bower_components/paper/dist/paper-full.js'
          ], function( Paper ){ 
                window.Paper=Paper;
             }
  );
</script>

In addition I wonder why the Paper variable starts with uppercase whereas in the code Paper1>>main it is referenced with lowercase paper

Update installation instructions for paperjs

Herby writes to the ML

No manual editing of bower.json

You can do it without manually editing bower.json. Just run

      bower install paper --save

You should go the standard way.
Standard way is to install by bower with --save, not editing bower.json by hand. It then should produce good pattern.

The usual pattern is something like "~0.5.3-alpha" which says "any from the same family as 0.5.3-alpha is", that is, 0.5.whatever.

typo in bower.json

The comma after "physicsjs": "~0.6.0" needs to be removed. bower install currently fails due to that typo

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.