Skip to content

Commit

Permalink
Merge pull request #129 from artem-mangilev/partial-compilation-serve
Browse files Browse the repository at this point in the history
Partial compilation serve
  • Loading branch information
artem-mangilev authored Jan 26, 2025
2 parents bd507c3 + 0cff72c commit c51d7ef
Show file tree
Hide file tree
Showing 43 changed files with 72 additions and 52 deletions.
10 changes: 10 additions & 0 deletions angular.json
Original file line number Diff line number Diff line change
Expand Up @@ -106,6 +106,13 @@
],
"outputHashing": "all"
},
"hybrid": {
"tsConfig": "projects/ngx-vflow-demo/tsconfig.hybrid.json",
"optimization": false,
"extractLicenses": false,
"sourceMap": true,
"namedChunks": true
},
"development": {
"optimization": false,
"extractLicenses": false,
Expand All @@ -121,6 +128,9 @@
"production": {
"buildTarget": "ngx-vflow-demo:build:production"
},
"hybrid": {
"buildTarget": "ngx-vflow-demo:build:hybrid"
},
"development": {
"buildTarget": "ngx-vflow-demo:build:development"
}
Expand Down
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
"scripts": {
"ng": "ng",
"start": "ng serve",
"start:hybrid": "ng build ngx-vflow-lib --watch & ng serve --configuration hybrid",
"build": "ng build",
"watch": "ng build --watch --configuration development",
"test": "ng test",
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { ChangeDetectionStrategy, Component } from '@angular/core';
import { Connection, ConnectionSettings, Edge, Node, Vflow } from 'projects/ngx-vflow-lib/src/public-api';
import { Connection, ConnectionSettings, Edge, Node, Vflow } from 'ngx-vflow';

@Component({
template: `<vflow
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { ChangeDetectionStrategy, Component } from '@angular/core';
import { Connection, Edge, Node, Vflow } from 'projects/ngx-vflow-lib/src/public-api';
import { Connection, Edge, Node, Vflow } from 'ngx-vflow';

@Component({
template: `<vflow view="auto" [nodes]="nodes" [edges]="edges" (onConnect)="createEdge($event)" /> `,
Expand Down
Original file line number Diff line number Diff line change
@@ -1,12 +1,5 @@
import { ChangeDetectionStrategy, Component } from '@angular/core';
import {
Connection,
ConnectionSettings,
CustomNodeComponent,
Edge,
Node,
Vflow,
} from 'projects/ngx-vflow-lib/src/public-api';
import { Connection, ConnectionSettings, CustomNodeComponent, Edge, Node, Vflow } from 'ngx-vflow';

@Component({
template: `
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { ChangeDetectionStrategy, Component } from '@angular/core';
import { ConnectionSettings, Edge, Node, Vflow } from 'projects/ngx-vflow-lib/src/public-api';
import { ConnectionSettings, Edge, Node, Vflow } from 'ngx-vflow';

@Component({
template: `<vflow view="auto" [nodes]="nodes" [edges]="edges" [connection]="connectionSettings" />`,
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { ChangeDetectionStrategy, Component } from '@angular/core';
import { Edge, Node, Vflow } from 'projects/ngx-vflow-lib/src/public-api';
import { Edge, Node, Vflow } from 'ngx-vflow';

@Component({
template: `<vflow view="auto" background="#bbe1fa" [nodes]="nodes" [edges]="edges" />`,
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { ChangeDetectionStrategy, Component } from '@angular/core';
import { Edge, Node, Vflow } from 'projects/ngx-vflow-lib/src/public-api';
import { Edge, Node, Vflow } from 'ngx-vflow';

@Component({
template: `<vflow view="auto" [nodes]="nodes" [edges]="edges" [background]="{ type: 'dots' }" />`,
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { ChangeDetectionStrategy, Component } from '@angular/core';
import { Edge, Node, Vflow } from 'projects/ngx-vflow-lib/src/public-api';
import { Edge, Node, Vflow } from 'ngx-vflow';

@Component({
template: `<vflow
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { ChangeDetectionStrategy, Component } from '@angular/core';
import { Edge, Node, Vflow } from 'projects/ngx-vflow-lib/src/public-api';
import { Edge, Node, Vflow } from 'ngx-vflow';

@Component({
template: `<vflow view="auto" [nodes]="nodes" [edges]="edges">
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { ChangeDetectionStrategy, Component } from '@angular/core';
import { Edge, Node, Vflow, Connection, ConnectionSettings } from 'projects/ngx-vflow-lib/src/public-api';
import { Edge, Node, Vflow, Connection, ConnectionSettings } from 'ngx-vflow';

@Component({
templateUrl: './custom-handles-demo.component.html',
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { Component, output, ChangeDetectionStrategy } from '@angular/core';
import { Vflow, CustomNodeComponent } from 'projects/ngx-vflow-lib/src/public-api';
import { Vflow, CustomNodeComponent } from 'ngx-vflow';

// --- Description of blue square component node
export interface BlueSquareData {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { Component, Output, EventEmitter, ChangeDetectionStrategy } from '@angular/core';
import { Vflow, CustomNodeComponent } from 'projects/ngx-vflow-lib/src/public-api';
import { Vflow, CustomNodeComponent } from 'ngx-vflow';

// --- Description of red square component node
export interface RedSquareData {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { ChangeDetectionStrategy, Component, inject } from '@angular/core';
import { NgDocNotifyService } from '@ng-doc/ui-kit';
import { ComponentNodeEvent, Edge, Node, Vflow } from 'projects/ngx-vflow-lib/src/public-api';
import { ComponentNodeEvent, Edge, Node, Vflow } from 'ngx-vflow';
import { BlueSquareNodeComponent, BlueSquareData } from './components/blue-square-node.component';
import { RedSquareNodeComponent, RedSquareData } from './components/red-square-node.component';

Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { ChangeDetectionStrategy, Component, signal } from '@angular/core';
import { DynamicNode, Edge, Vflow } from 'projects/ngx-vflow-lib/src/public-api';
import { DynamicNode, Edge, Vflow } from 'ngx-vflow';

@Component({
template: `<vflow view="auto" [nodes]="nodes" [edges]="edges">
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { ChangeDetectionStrategy, Component } from '@angular/core';
import { Edge, Node, Vflow } from 'projects/ngx-vflow-lib/src/public-api';
import { Edge, Node, Vflow } from 'ngx-vflow';

@Component({
template: `<vflow view="auto" [nodes]="nodes" [edges]="edges" />`,
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { ChangeDetectionStrategy, Component } from '@angular/core';
import { Node, Vflow } from 'projects/ngx-vflow-lib/src/public-api';
import { Node, Vflow } from 'ngx-vflow';

@Component({
template: `<vflow view="auto" [nodes]="nodes" />`,
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { ChangeDetectionStrategy, Component } from '@angular/core';
import { Edge, Node, Vflow } from 'projects/ngx-vflow-lib/src/public-api';
import { Edge, Node, Vflow } from 'ngx-vflow';

@Component({
templateUrl: './drag-handle-demo.component.html',
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { ChangeDetectionStrategy, Component } from '@angular/core';
import { Edge, Node, Vflow } from 'projects/ngx-vflow-lib/src/public-api';
import { Edge, Node, Vflow } from 'ngx-vflow';

@Component({
template: `<vflow view="auto" [nodes]="nodes" [edges]="edges" />`,
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { ChangeDetectionStrategy, Component, TemplateRef, inject, viewChild } from '@angular/core';
import { NgDocNotifyService } from '@ng-doc/ui-kit';
import { Connection, Edge, EdgeChange, Node, NodeChange, Vflow } from 'projects/ngx-vflow-lib/src/public-api';
import { Connection, Edge, EdgeChange, Node, NodeChange, Vflow } from 'ngx-vflow';

@Component({
templateUrl: './handling-changes-demo.component.html',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import {
NodePositionChange,
NodeSelectedChange,
Vflow,
} from 'projects/ngx-vflow-lib/src/public-api';
} from 'ngx-vflow';

@Component({
templateUrl: './handling-changes-filtered-demo.component.html',
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { ChangeDetectionStrategy, Component } from '@angular/core';
import { KeyboardShortcuts, Node, Vflow } from 'projects/ngx-vflow-lib/src/public-api';
import { KeyboardShortcuts, Node, Vflow } from 'ngx-vflow';

@Component({
template: `<vflow view="auto" [nodes]="nodes" [keyboardShortcuts]="shortcuts" />`,
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { ChangeDetectionStrategy, Component } from '@angular/core';
import { Edge, Node, Vflow } from 'projects/ngx-vflow-lib/src/public-api';
import { Edge, Node, Vflow } from 'ngx-vflow';

@Component({
template: `<vflow view="auto" [nodes]="nodes" [edges]="edges">
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { ChangeDetectionStrategy, Component } from '@angular/core';
import { Connection, ConnectionSettings, Edge, Node, Vflow } from 'projects/ngx-vflow-lib/src/public-api';
import { Connection, ConnectionSettings, Edge, Node, Vflow } from 'ngx-vflow';

@Component({
template: `<vflow
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { ChangeDetectionStrategy, Component } from '@angular/core';
import { Edge, Node, Vflow } from 'projects/ngx-vflow-lib/src/public-api';
import { Edge, Node, Vflow } from 'ngx-vflow';

@Component({
template: `<vflow view="auto" [nodes]="nodes" [edges]="edges">
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { CommonModule } from '@angular/common';
import { ChangeDetectionStrategy, Component } from '@angular/core';
import { Edge, Node, Vflow, Connection } from 'projects/ngx-vflow-lib/src/public-api';
import { Edge, Node, Vflow, Connection } from 'ngx-vflow';

@Component({
templateUrl: './multiple-connection-points-demo.component.html',
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { ChangeDetectionStrategy, Component } from '@angular/core';
import { Edge, Node, Vflow } from 'projects/ngx-vflow-lib/src/public-api';
import { Edge, Node, Vflow } from 'ngx-vflow';

@Component({
templateUrl: './node-toolbar-demo.component.html',
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { ChangeDetectionStrategy, Component } from '@angular/core';
import { Edge, Node, Vflow } from 'projects/ngx-vflow-lib/src/public-api';
import { Edge, Node, Vflow } from 'ngx-vflow';

@Component({
template: `<vflow view="auto" [nodes]="nodes" [edges]="edges" />`,
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { ChangeDetectionStrategy, Component } from '@angular/core';
import { Node, Vflow } from 'projects/ngx-vflow-lib/src/public-api';
import { Node, Vflow } from 'ngx-vflow';

@Component({
template: `<vflow view="auto" [nodes]="nodes">
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { ChangeDetectionStrategy, Component } from '@angular/core';
import { Edge, Node, Vflow } from 'projects/ngx-vflow-lib/src/public-api';
import { Edge, Node, Vflow } from 'ngx-vflow';

@Component({
template: `
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { ChangeDetectionStrategy, Component } from '@angular/core';
import { Edge, Node, Vflow } from 'projects/ngx-vflow-lib/src/public-api';
import { Edge, Node, Vflow } from 'ngx-vflow';

@Component({
templateUrl: './selecting-demo.component.html',
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { ChangeDetectionStrategy, Component } from '@angular/core';
import { Edge, Node, Vflow } from 'projects/ngx-vflow-lib/src/public-api';
import { Edge, Node, Vflow } from 'ngx-vflow';

@Component({
template: `<vflow view="auto" [nodes]="nodes" [edges]="edges">
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { ChangeDetectionStrategy, Component } from '@angular/core';
import { Edge, Node, Vflow } from 'projects/ngx-vflow-lib/src/public-api';
import { Edge, Node, Vflow } from 'ngx-vflow';

@Component({
template: `<vflow view="auto" [nodes]="nodes" [edges]="edges" />`,
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { ChangeDetectionStrategy, Component } from '@angular/core';
import { Edge, Node, Vflow } from 'projects/ngx-vflow-lib/src/public-api';
import { Edge, Node, Vflow } from 'ngx-vflow';

@Component({
template: `<vflow [nodes]="nodes" [edges]="edges" [view]="[600, 600]" />`,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import {
ConnectionSettings,
isComponentStaticNode,
isDefaultStaticNode,
} from 'projects/ngx-vflow-lib/src/public-api';
} from 'ngx-vflow';
import { ComplexCustomNodeComponent, ComplexCustomNodeData } from './components/complex-custom-node.component';
import { SimpleCustomNodeComponent } from './components/simple-custom-node.component';

Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { ChangeDetectionStrategy, Component, WritableSignal } from '@angular/core';
import { Vflow, CustomNodeComponent } from 'projects/ngx-vflow-lib/src/public-api';
import { Vflow, CustomNodeComponent } from 'ngx-vflow';

export interface ComplexCustomNodeData {
id: {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { ChangeDetectionStrategy, Component } from '@angular/core';
import { CustomNodeComponent, Vflow } from 'projects/ngx-vflow-lib/src/public-api';
import { CustomNodeComponent, Vflow } from 'ngx-vflow';

@Component({
template: `<div class="node">
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { ChangeDetectionStrategy, Component, signal, viewChild } from '@angular/core';
import * as d3 from 'd3-force';
import { DynamicNode, Edge, VflowComponent, Vflow } from 'projects/ngx-vflow-lib/src/public-api';
import { DynamicNode, Edge, VflowComponent, Vflow } from 'ngx-vflow';

@Component({
templateUrl: './force-layout-demo.component.html',
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { ChangeDetectionStrategy, Component, OnInit, signal, viewChild, WritableSignal } from '@angular/core';
import init, { DirectedGraph, VertexRef } from '@vizdom/vizdom-ts-web';
import { Edge, Node, VflowComponent, Vflow } from 'projects/ngx-vflow-lib/src/public-api';
import { Edge, Node, VflowComponent, Vflow } from 'ngx-vflow';

@Component({
templateUrl: './vizdom-layout-demo.component.html',
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { ChangeDetectionStrategy, Component } from '@angular/core';
import { Edge, Node, Vflow } from 'projects/ngx-vflow-lib/src/public-api';
import { Edge, Node, Vflow } from 'ngx-vflow';

@Component({
templateUrl: './delete-selected-demo.component.html',
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { ChangeDetectionStrategy, Component, viewChild } from '@angular/core';
import { DndDropEvent, DndModule } from 'ngx-drag-drop';
import { Connection, Edge, Node, VflowComponent, Vflow } from 'projects/ngx-vflow-lib/src/public-api';
import { Connection, Edge, Node, VflowComponent, Vflow } from 'ngx-vflow';

@Component({
templateUrl: './drag-and-drop-nodes-demo.component.html',
Expand Down
16 changes: 16 additions & 0 deletions projects/ngx-vflow-demo/tsconfig.hybrid.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
{
"extends": "../../tsconfig.json",
"compilerOptions": {
"outDir": "../../out-tsc/app",
"types": [],
// override paths from root tsconfig.json
"paths": {
"@ng-doc/generated": ["ng-doc/ngx-vflow-demo/index.ts"],
"@ng-doc/generated/*": ["ng-doc/ngx-vflow-demo/*"],
// alias to production build of the library instead of building it as part of application
"ngx-vflow": ["dist/ngx-vflow-lib"]
}
},
"files": ["src/main.ts"],
"include": ["src/**/*.d.ts"]
}
12 changes: 6 additions & 6 deletions tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,11 +11,6 @@
"noImplicitReturns": true,
"noFallthroughCasesInSwitch": true,
"sourceMap": true,
"paths": {
"@ng-doc/generated": ["ng-doc/ngx-vflow-demo/index.ts"],
"@ng-doc/generated/*": ["ng-doc/ngx-vflow-demo/*"],
"ngx-vflow-lib": ["dist/ngx-vflow-lib"]
},
"declaration": false,
"downlevelIteration": true,
"experimentalDecorators": true,
Expand All @@ -26,7 +21,12 @@
"useDefineForClassFields": false,
"lib": ["ES2022", "dom"],
"stripInternal": true,
"skipLibCheck": true
"skipLibCheck": true,
"paths": {
"@ng-doc/generated": ["ng-doc/ngx-vflow-demo/index.ts"],
"@ng-doc/generated/*": ["ng-doc/ngx-vflow-demo/*"],
"ngx-vflow": ["projects/ngx-vflow-lib/src/public-api"]
}
},
"angularCompilerOptions": {
"enableI18nLegacyMessageIdFormat": false,
Expand Down

0 comments on commit c51d7ef

Please sign in to comment.