diff --git a/build/README.md b/build/README.md deleted file mode 100644 index 3e0cc39d0..000000000 --- a/build/README.md +++ /dev/null @@ -1,103 +0,0 @@ -# litegraph.js - -A library in Javascript to create graphs in the browser similar to [PureData](https://puredata.info/). Nodes can be programmed easily and it includes an editor to construct the graphs. - -It can be integrated easily in any existing web applications and graphs can be run without the need of the editor. - - - -## Installation - -``` -npm install litegraph.js -``` - -## First project ## - -```html - -
- - - - - - - -``` - -## How to code a new Node type - -Here is an example of how to build a node that sums two inputs: - -```javascript -//node constructor class -function MyAddNode() -{ - this.addInput("A","number"); - this.addInput("B","number"); - this.addOutput("A+B","number"); -} - -//name to show -MyAddNode.title = "Sum"; - -//function to call when the node is executed -MyAddNode.prototype.onExecute = function() -{ - var A = this.getInputData(0); - if( A === undefined ) - A = 0; - var B = this.getInputData(1); - if( B === undefined ) - B = 0; - this.setOutputData( 0, A + B ); -} - -//register in the system -LiteGraph.registerNodeType("basic/sum", MyAddNode ); - -``` - - -## Projects using it - -### [webglstudio.org](http://webglstudio.org) - - - -### [MOI Elephant](http://moiscript.weebly.com/elephant-systegraveme-nodal.html) - - - -### [Mynodes.NET](http://www.mynodes.net) - - - -## Utils ------ - -It includes several commands in the utils folder to generate doc, check errors and build minifyed version. - - -## Feedback --------- - -You can write any feedback to javi.agenjo@gmail.com diff --git a/build/package.json b/build/package.json deleted file mode 100644 index 372fdec0f..000000000 --- a/build/package.json +++ /dev/null @@ -1,9 +0,0 @@ -{ - "version": "0.2.1", - "name": "litegraph.js", - "main": "litegraph.js", - "description": "A graph node editor similar to PD or UDK Blueprints, it works in a HTML5 Canvas and allow to exported graphs to be included in applications.", - "author": "jagenjo", - "license": "MIT", - "scripts": {} -} \ No newline at end of file diff --git a/gruntfile.js b/gruntfile.js index 490c9fbde..4d481acad 100644 --- a/gruntfile.js +++ b/gruntfile.js @@ -20,19 +20,6 @@ module.exports = function (grunt) { dest: 'build/litegraph.js' } }, - copy: { - parts: { - files: [ - { - expand: true, - flatten: true, - cwd: '', - src: ['README.md'], - dest: 'build/' - } - ] - } - }, clean: { build: {src: ['build/*']} }, @@ -55,28 +42,28 @@ module.exports = function (grunt) { } }) - grunt.registerTask('buildPackage', function () { - var pkg = grunt.config.data.pkg - var newPackage = { - version: pkg.version, - name: 'litegraph.js', //* Static name without ogranisation - main: 'litegraph.js', - description: pkg.description, - dependencies: pkg.dependencies, - author: pkg.author, - license: 'MIT', - scripts: { + // grunt.registerTask('buildPackage', function () { + // var pkg = grunt.config.data.pkg + // var newPackage = { + // version: pkg.version, + // name: 'litegraph.js', //* Static name without ogranisation + // main: 'litegraph.js', + // description: pkg.description, + // dependencies: pkg.dependencies, + // author: pkg.author, + // license: 'MIT', + // scripts: { - } - } + // } + // } - grunt.file.write('build/package.json', JSON.stringify(newPackage, undefined, 2)) - }) + // grunt.file.write('build/package.json', JSON.stringify(newPackage, undefined, 2)) + // }) grunt.loadNpmTasks('grunt-contrib-concat') grunt.loadNpmTasks('grunt-contrib-copy') grunt.loadNpmTasks('grunt-closure-tools') grunt.loadNpmTasks('grunt-contrib-clean') - grunt.registerTask('build', ['buildPackage', 'copy:parts', 'concat:build', 'closureCompiler']) + grunt.registerTask('build', ['concat:build', 'closureCompiler']) } diff --git a/package.json b/package.json index bdd06735d..0ffa7a3d0 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { - "name": "@skymaker/litegraph.js", - "version": "0.2.1", + "name": "litegraph.js", + "version": "0.3.0-0", "description": "A graph node editor similar to PD or UDK Blueprints, it works in a HTML5 Canvas and allow to exported graphs to be included in applications.", "main": "build/litegraph.js", "directories": { @@ -18,6 +18,10 @@ }, "author": "jagenjo", "license": "MIT", + "files": [ + "build", + "css" + ], "bugs": { "url": "https://github.com/jagenjo/litegraph.js/issues" },