flowjs / ngx-flow

flow.js file upload for angular
MIT License
60 stars 19 forks source link

Cannot find namespace 'flowjs'. #90

Closed sebastiencl closed 2 years ago

sebastiencl commented 2 years ago

Hi all,

I'm currently facing an issue. I'm running an Angular 13 app with ngx-flow 0.5.0.

When i try to build my app, I have several error messages:

Error: node_modules/@flowjs/ngx-flow/lib/button.directive.d.ts:1:23 - error TS2688: Cannot find type definition file for 'flowjs'.
1 /// <reference types="flowjs" />

Error: node_modules/@flowjs/ngx-flow/lib/button.directive.d.ts:10:23 - error TS2503: Cannot find namespace 'flowjs'.
10     protected _flow?: flowjs.Flow;

Error: node_modules/@flowjs/ngx-flow/lib/button.directive.d.ts:11:20 - error TS2503: Cannot find namespace 'flowjs'.
11     set flow(flow: flowjs.Flow);

Error: node_modules/@flowjs/ngx-flow/lib/drop.directive.d.ts:1:23 - error TS2688: Cannot find type definition file for 'flowjs'.
1 /// <reference types="flowjs" />

Error: node_modules/@flowjs/ngx-flow/lib/drop.directive.d.ts:7:24 - error TS2503: Cannot find namespace 'flowjs'.
7     protected flowJs?: flowjs.Flow;

Error: node_modules/@flowjs/ngx-flow/lib/drop.directive.d.ts:8:20 - error TS2503: Cannot find namespace 'flowjs'.
8     set flow(flow: flowjs.Flow);

Error: node_modules/@flowjs/ngx-flow/lib/flow-constructor.d.ts:1:23 - error TS2688: Cannot find type definition file for 'flowjs'.

1 /// <reference types="flowjs" />

Error: node_modules/@flowjs/ngx-flow/lib/flow-constructor.d.ts:3:23 - error TS2503: Cannot find namespace 'flowjs'.
3     new (flowOptions: flowjs.FlowOptions): flowjs.Flow;

Error: node_modules/@flowjs/ngx-flow/lib/flow-constructor.d.ts:3:44 - error TS2503: Cannot find namespace 'flowjs'.
3     new (flowOptions: flowjs.FlowOptions): flowjs.Flow;

Error: node_modules/@flowjs/ngx-flow/lib/flow.directive.d.ts:1:23 - error TS2688: Cannot find type definition file for 'flowjs'.
1 /// <reference types="flowjs" />

Error: node_modules/@flowjs/ngx-flow/lib/flow.directive.d.ts:7:44 - error TS2503: Cannot find namespace 'flowjs'.
7 export interface FlowChangeEvent<T extends flowjs.EventName> {

Error: node_modules/@flowjs/ngx-flow/lib/flow.directive.d.ts:9:12 - error TS2503: Cannot find namespace 'flowjs'.
9     event: flowjs.FlowEventFromEventName<T>;

Error: node_modules/@flowjs/ngx-flow/lib/flow.directive.d.ts:17:29 - error TS2503: Cannot find namespace 'flowjs'.
17     set flowConfig(options: flowjs.FlowOptions);

Error: node_modules/@flowjs/ngx-flow/lib/flow.directive.d.ts:18:13 - error TS2503: Cannot find namespace 'flowjs'.
18     flowJs: flowjs.Flow;

Error: node_modules/@flowjs/ngx-flow/lib/flow.directive.d.ts:19:43 - error TS2307: Cannot find module 'flowjs' or its corresponding type declarations.
19     protected flow$: ReplaySubject<import("flowjs").Flow>;

Error: node_modules/@flowjs/ngx-flow/lib/flow.directive.d.ts:21:69 - error TS2307: Cannot find module 'flowjs' or its corresponding type declarations.
21     events$: Observable<NgxFlowEvent | FlowChangeEvent<keyof import("flowjs").FlowEventMap>>;

Error: node_modules/@flowjs/ngx-flow/lib/flow.directive.d.ts:32:40 - error TS2503: Cannot find namespace 'flowjs'.
32     protected listenForEvent<T extends flowjs.EventName>(flow: flowjs.Flow, eventName: T): Observable<{

Error: node_modules/@flowjs/ngx-flow/lib/flow.directive.d.ts:32:64 - error TS2503: Cannot find namespace 'flowjs'.
32     protected listenForEvent<T extends flowjs.EventName>(flow: flowjs.Flow, eventName: T): Observable<{

Error: node_modules/@flowjs/ngx-flow/lib/flow.directive.d.ts:34:16 - error TS2503: Cannot find namespace 'flowjs'.
34         event: flowjs.FlowEventFromEventName<T>;

Error: node_modules/@flowjs/ngx-flow/lib/transfer.d.ts:1:23 - error TS2688: Cannot find type definition file for 'flowjs'.

1 /// <reference types="flowjs" />

Error: node_modules/@flowjs/ngx-flow/lib/transfer.d.ts:5:15 - error TS2503: Cannot find namespace 'flowjs'.
5     flowFile: flowjs.FlowFile;

Error: node_modules/@flowjs/ngx-flow/lib/upload-state.d.ts:1:23 - error TS2688: Cannot find type definition file for 'flowjs'.
1 /// <reference types="flowjs" />

Error: node_modules/@flowjs/ngx-flow/lib/upload-state.d.ts:6:11 - error TS2503: Cannot find namespace 'flowjs'.
6     flow: flowjs.Flow;

Any ideas ?

sebastiencl commented 2 years ago

I fixed my issue

npm install --save @types/flowjs