This repository contains an examples for Rete.js version 1.
However, if you need the source code for examples for the next major version, please check out the Examples page.
This repository contains an examples for Rete.js version 1.
However, if you need the source code for examples for the next major version, please check out the Examples page.
(subj)
Hi,
I am using example of angular. I have used only rete folder(in app) in example of angular and installed required plugins.
I am getting following error while running on browser.
please check my angular.json
`{
"$schema": "./node_modules/@angular/cli/lib/config/schema.json",
"version": 1,
"cli": {
"packageManager": "npm"
},
"newProjectRoot": "projects",
"projects": {
"testing": {
"root": "",
"sourceRoot": "src",
"projectType": "application",
"prefix": "app",
"schematics": {},
"architect": {
"build": {
"builder": "@angular-devkit/build-angular:browser",
"options": {
"outputPath": "dist/testing",
"index": "src/index.html",
"main": "src/main.ts",
"polyfills": "src/polyfills.ts",
"tsConfig": "src/tsconfig.app.json",
"assets": [
"src/favicon.ico",
"src/assets"
],
"styles": [
"src/styles.css"
],
"scripts": []
},
"configurations": {
"production": {
"fileReplacements": [
{
"replace": "src/environments/environment.ts",
"with": "src/environments/environment.prod.ts"
}
],
"optimization": true,
"outputHashing": "all",
"sourceMap": false,
"extractCss": true,
"namedChunks": false,
"aot": true,
"extractLicenses": true,
"vendorChunk": false,
"buildOptimizer": true,
"budgets": [
{
"type": "initial",
"maximumWarning": "2mb",
"maximumError": "5mb"
}
]
}
}
},
"serve": {
"builder": "@angular-devkit/build-angular:dev-server",
"options": {
"browserTarget": "testing:build"
},
"configurations": {
"production": {
"browserTarget": "testing:build:production"
}
}
},
"extract-i18n": {
"builder": "@angular-devkit/build-angular:extract-i18n",
"options": {
"browserTarget": "testing:build"
}
},
"test": {
"builder": "@angular-devkit/build-angular:karma",
"options": {
"main": "src/test.ts",
"polyfills": "src/polyfills.ts",
"tsConfig": "src/tsconfig.spec.json",
"karmaConfig": "src/karma.conf.js",
"styles": [
"src/styles.css"
],
"scripts": [],
"assets": [
"src/favicon.ico",
"src/assets"
]
}
},
"lint": {
"builder": "@angular-devkit/build-angular:tslint",
"options": {
"tsConfig": [
"src/tsconfig.app.json",
"src/tsconfig.spec.json"
],
"exclude": [
"**/node_modules/**"
]
}
}
}
},
"testing-e2e": {
"root": "e2e/",
"projectType": "application",
"prefix": "",
"architect": {
"e2e": {
"builder": "@angular-devkit/build-angular:protractor",
"options": {
"protractorConfig": "e2e/protractor.conf.js",
"devServerTarget": "testing:serve"
},
"configurations": {
"production": {
"devServerTarget": "testing:serve:production"
}
}
},
"lint": {
"builder": "@angular-devkit/build-angular:tslint",
"options": {
"tsConfig": "e2e/tsconfig.e2e.json",
"exclude": [
"**/node_modules/**"
]
}
}
}
}
},
"defaultProject": "testing"
}`
also check my package.json
`
{
"name": "testing",
"version": "0.0.0",
"scripts": {
"ng": "ng",
"start": "ng serve",
"build": "ng build",
"test": "ng test",
"lint": "ng lint",
"e2e": "ng e2e"
},
"private": true,
"dependencies": {
"@angular/animations": "~7.2.0",
"@angular/common": "~7.2.0",
"@angular/compiler": "~7.2.0",
"@angular/core": "~7.2.0",
"@angular/forms": "~7.2.0",
"@angular/platform-browser": "~7.2.0",
"@angular/platform-browser-dynamic": "~7.2.0",
"@angular/router": "~7.2.0",
"core-js": "^2.5.4",
"regenerator-runtime": "^0.13.3",
"rete": "^1.4.1-rc.1",
"rete-area-plugin": "^0.2.1",
"rete-connection-plugin": "^0.6.4",
"rete-context-menu-plugin": "^0.3.4",
"rete-readonly-plugin": "^0.3.0",
"rete-vue-render-plugin": "^0.3.3",
"rxjs": "~6.3.3",
"tslib": "^1.9.0",
"vue": "^2.6.10",
"zone.js": "~0.8.26"
},
"devDependencies": {
"@angular-devkit/build-angular": "~0.13.0",
"@angular/cli": "~7.3.9",
"@angular/compiler-cli": "~7.2.0",
"@angular/language-service": "~7.2.0",
"@types/node": "~8.9.4",
"@types/jasmine": "~2.8.8",
"@types/jasminewd2": "~2.0.3",
"codelyzer": "~4.5.0",
"jasmine-core": "~2.99.1",
"jasmine-spec-reporter": "~4.2.1",
"karma": "~4.0.0",
"karma-chrome-launcher": "~2.2.0",
"karma-coverage-istanbul-reporter": "~2.0.1",
"karma-jasmine": "~1.1.2",
"karma-jasmine-html-reporter": "^0.2.2",
"protractor": "~5.4.0",
"ts-node": "~7.0.0",
"tslint": "~5.11.0",
"typescript": "~3.2.2"
}
}
`
any idea why this is happening ?
Thanks.
If i try to modify the contents of the alert message in the Tasks example by changing the text in the input box, all alerts from that node become "NaN".
Firefox 59.0.2
Hi,
I am facing an issue when i try to build angular project in production.
giving me following error
Cannot set property ‘mustUseProp’ of undefined
Any solution ?
Thanks.
I have tried install and create Rete.Engine to one of my service on FeathersJS app but it got error regeneratorRuntime is not defined
After searching i found issues #16 maybe can solved my problem with install babel-polyfill
and config at .babelrc
Polyfills are missed in your project
https://github.com/retejs/examples/blob/master/Angular/src/polyfills.ts
but i dont know how to config that solution, there is no .babelrc
file in my project.
I want to create a node by clicking on the button.
And I'll store it as json and send the information to the server.
please help me
Good afternoon,
Is there any way to change the component color or node color on real time in Angular?
Thank you in advance.
Good afternoon,
Eveytime that I double click it zoom on that specific area, how can I disable this?
Thank you in advance.
In task example Array this.task.outputs
must be an object otherwise plugin raises exception
Hi,
Is there a way of removing the following text in the console, when running with angular renderer i development mode?
You are running Vue in development mode.
Make sure to turn on production mode when deploying for production.
See more tips at https://vuejs.org/guide/deployment.html
I dont have any Vue libraries in my package.json and I dont understand why this print in the console is there in the first place.
EtlComponent.html:51 ERROR ReferenceError: D3NE is not defined
at EtlGraphComponent.ngAfterViewInit (etl-graph.component.ts:16)
at callProviderLifecycles (core.js:12706)
at callElementProvidersLifecycles (core.js:12673)
at callLifecycleHooksChildrenFirst (core.js:12656)
at checkAndUpdateView (core.js:13811)
at callViewAction (core.js:14153)
at execComponentViewsAction (core.js:14085)
at checkAndUpdateView (core.js:13808)
at callViewAction (core.js:14153)
at execEmbeddedViewsAction (core.js:14111)
Could not install from "....\D3 Node Editor" as it does not contain a package.json file.
my package json
{
"name": "angular",
"version": "0.0.0",
"license": "MIT",
"scripts": {
"ng": "ng",
"start": "ng serve",
"build": "ng build",
"test": "ng test",
"lint": "ng lint",
"e2e": "ng e2e"
},
"private": true,
"dependencies": {
"@angular/animations": "^5.2.5",
"@angular/common": "^5.2.5",
"@angular/compiler": "^5.2.5",
"@angular/core": "^5.2.5",
"@angular/forms": "^5.2.5",
"@angular/http": "^5.2.5",
"@angular/platform-browser": "^5.2.5",
"@angular/platform-browser-dynamic": "^5.2.5",
"@angular/router": "^5.2.5",
"alight": "^0.14.1",
"core-js": "^2.4.1",
"d3": "^4.13.0",
"d3-node-editor": "file:../../D3 Node Editor",
"rxjs": "^5.5.2",
"zone.js": "^0.8.14"
},
"devDependencies": {
"@angular/cli": "1.6.0",
"@angular/compiler-cli": "^5.2.5",
"@angular/language-service": "^5.2.5",
"@types/jasmine": "~2.5.53",
"@types/jasminewd2": "~2.0.2",
"@types/node": "~6.0.60",
"codelyzer": "^4.0.1",
"jasmine-core": "~2.6.2",
"jasmine-spec-reporter": "~4.1.0",
"karma": "~1.7.0",
"karma-chrome-launcher": "~2.1.1",
"karma-cli": "~1.0.1",
"karma-coverage-istanbul-reporter": "^1.2.1",
"karma-jasmine": "~1.1.0",
"karma-jasmine-html-reporter": "^0.2.2",
"protractor": "~5.1.2",
"ts-node": "~3.2.0",
"tslint": "~5.7.0",
"typescript": "~2.4.2"
}
}
Hi,
When I run npm start everything runs fine in the development phase, but when I run npm run build:prod it gives me this error.
ERROR in : Unexpected value 'ReteModule in ../node_modules/rete-angular-render-plugin/dist/module.d.ts' imported by the module 'GameDbModule in ../src/app/pa
ges/game-db/game-db.module.ts'. Please add a @NgModule annotation.
@NgModule({
imports: [
CommonModule,
ReactiveFormsModule,
// Third party
ReteModule,
//... Rest of the code
],
declarations: [
// Rete
ReteComponent,
NumberComponent,
MyNodeComponent,
],
entryComponents: [
// Rete
ReteComponent,
NumberComponent,
MyNodeComponent,
],
})
export class GameDbModule {
static forRoot(): ModuleWithProviders {
return <ModuleWithProviders>{
ngModule: GameDbModule,
// providers: [
// SmartTableService<>,
// ],
};
}
}
Hi,
I am trying to run this example using Angular 5 but after following all the steps I got this error from the browser:
editor.component.ts:24 -> in this line I have var numSocket = new D3NW.Socket("number", "Number value", "hint");
EditorComponent_Host.ngfactory.js? [sm]:1 ERROR TypeError: __WEBPACK_IMPORTED_MODULE_1_d3_node_editor___default.a.Socket is not a constructor
at EditorComponent.ngAfterViewInit (editor.component.ts:24)
at callProviderLifecycles (core.js:12691)
at callElementProvidersLifecycles (core.js:12658)
at callLifecycleHooksChildrenFirst (core.js:12641)
at checkAndUpdateView (core.js:13796)
at callViewAction (core.js:14138)
at execEmbeddedViewsAction (core.js:14096)
at checkAndUpdateView (core.js:13788)
at callViewAction (core.js:14138)
at execComponentViewsAction (core.js:14070)
any suggestion?
Good evening,
Is there any way to move at the same time all the connected nodes?
Right now Im able to change the position from the nodes but they just update the view until I select each one of them, how can I refresh the whole view or all the nodes?
Thank you in advance for the assistance.
Hi,
I am using angular5 with express.js. I have basically copied and pasted the example project in my angular application but the flow diagram is not showing in the browser. If I inspect the html page then I can see that the elements are being rendered but they are "invisible" in the browser.
Good afternoon,
Im removing an output dynamically but using the removeOutput method from the node but Im having the following error:
After reviewing the libraries and trying to figure out what is wrong, it seems to be that the socket from the output is not being removed and even after updating the node, when we click the socket its still grabbing the previous name from the html.
Do you know how can I fix this?
Thank you in advance.
Hello.
I am trying to update the Angular example to [email protected]
I have had to update the arguments to create AddComponent and NumComponent:
const out1 = new Output('num', 'Number', numSocket);
const inp1 = new Input('num1', 'Number', numSocket); const inp2 = new Input('num2', 'Number', numSocket);
I have had to add the 'key' to 'super()' at NumControl constructor:
super(key);
And I have had to add a 'key' to the NumControl for AddComponent:
node.addControl(new NumControl(this.editor, 'preview', true))
When I try to run ($ng serve) it returns me an error:
ERROR Error: "Uncaught (in promise): TypeError: Value of argument "output" violates contract Expected: Output Got: void
I have found that this error rises at 'rete.component.ts' at the connection of the components:
editor.connect(n1.outputs[0], add.inputs[0]);
editor.connect(n2.outputs[0], add.inputs[1]);
(I have tried editor.connect(n1.outputs['num'], add.inputs['num1']);
... as well).
I have checked the outputs of the objects of NumComponent and AddComponent, and they are not null or void.
Hi,
On Vue3 example, the context menu does not work. (when right click on editor)
the error in console browser is:
Uncaught TypeError: vue__WEBPACK_IMPORTED_MODULE_1__.default is not a constructor
at MainMenu._default (context-menu-plugin.esm.js?1b64:1073)
at new MainMenu (context-menu-plugin.esm.js?1b64:1128)
at eval (context-menu-plugin.esm.js?1b64:1326)
at eval (rete.esm.js?f5d5:580)
at Array.reduce ()
at EditorView.trigger (rete.esm.js?f5d5:579)
at HTMLDivElement.eval (rete.esm.js?f5d5:1456)
what i know is the example is vue3 but the context-menu-plugin is vue2....
Thanks
Good afternoon,
Can vuetify or vue-material used on custom nodes?
How can I import this modules?
Thank you in advance.
Vue3 example has errors in browser console and right click is not working.
2context-menu-plugin.esm.js?1b64:1073 Uncaught TypeError: vue__WEBPACK_IMPORTED_MODULE_1__.default is not a constructor
at MainMenu._default (context-menu-plugin.esm.js?1b64:1073:1)
at new MainMenu (context-menu-plugin.esm.js?1b64:1128:1)
at eval (context-menu-plugin.esm.js?1b64:1326:1)
at eval (rete.esm.js?f5d5:580:1)
at Array.reduce ()
at EditorView.trigger (rete.esm.js?f5d5:579:1)
at HTMLDivElement.eval (rete.esm.js?f5d5:1456:1)
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.