microsoft / Reporting-Services

Git repo for SQL Server Reporting Services and Power BI paginated report samples, and community projects
MIT License
427 stars 363 forks source link

npm run dev error,failed to build #180

Open 939481896 opened 4 years ago

939481896 commented 4 years ago

npm run dev

report-server-api-sample@1.0.0 dev C:\Users\H381850\WorkSpace\Web Portal\Report\Reporting-Services-master\APISamples\typescript webpack-dev-server

Project is running at http://0.0.0.0:8082/ webpack output is served from / 404s will fallback to /index.html ts-loader: Using typescript@2.9.2 and C:\Users\H381850\WorkSpace\Web Portal\Report\Reporting-Services-master\APISamples\typescript\tsconfig.json Hash: 38ee4a8496b3028e5d22 Version: webpack 3.12.0 Time: 9979ms Asset Size Chunks Chunk Names main.js 3.26 MB 0 [emitted] [big] main index.html 867 bytes [emitted] [0] multi (webpack)-dev-server/client?http://0.0.0.0:8082 ./src/app.tsx 40 bytes {0} [built] [./node_modules/ansi-html/index.js] ./node_modules/ansi-html/index.js 4.26 kB {0} [built] [./node_modules/ansi-regex/index.js] ./node_modules/ansi-regex/index.js 135 bytes {0} [built] [./node_modules/html-entities/lib/index.js] ./node_modules/html-entities/lib/index.js 449 bytes {0} [built] [./node_modules/loglevel/lib/loglevel.js] ./node_modules/loglevel/lib/loglevel.js 8.61 kB {0} [built] [./node_modules/react-router-dom/es/index.js] ./node_modules/react-router-dom/es/index.js 1.01 kB {0} [built] [./node_modules/strip-ansi/index.js] ./node_modules/strip-ansi/index.js 161 bytes {0} [built] [./node_modules/url/url.js] ./node_modules/url/url.js 23.3 kB {0} [built] [./node_modules/webpack-dev-server/client/index.js?http://0.0.0.0:8082] (webpack)-dev-server/client?http://0.0.0.0:8082 7.93 kB {0} [built] [./node_modules/webpack-dev-server/client/overlay.js] (webpack)-dev-server/client/overlay.js 3.67 kB {0} [built] [./node_modules/webpack-dev-server/client/socket.js] (webpack)-dev-server/client/socket.js 1.08 kB {0} [built] [./node_modules/webpack/hot ^.\/log$] (webpack)/hot nonrecursive ^.\/log$ 170 bytes {0} [built] [./node_modules/webpack/hot/emitter.js] (webpack)/hot/emitter.js 77 bytes {0} [built] [./src/app.tsx] ./src/app.tsx 516 bytes {0} [built] [4 errors] [./src/home.tsx] ./src/home.tsx 5.53 kB {0} [built] [6 errors]

So what can I do for this error. Thank you for your help.

pguidoPokerAtlas commented 4 years ago

Same issue as above. Can't get it to build without lots of errors. Here are some examples of the errors:

ERROR in ./src/home.tsx (22,40): error TS2345: Argument of type '(items: CatalogItem[]) => void' is not assignable to parameter of type '((value: CatalogItem | CatalogItem[]) => void | PromiseLike) | null | undefined'. Type '(items: CatalogItem[]) => void' is not assignable to type '(value: CatalogItem | CatalogItem[]) => void | PromiseLike'. Types of parameters 'items' and 'value' are incompatible. Type 'CatalogItem | CatalogItem[]' is not assignable to type 'CatalogItem[]'. Type 'CatalogItem' is not assignable to type 'CatalogItem[]'. Property 'length' is missing in type 'CatalogItem'.

ERROR in ./src/home.tsx (28,19): error TS2345: Argument of type '(items: CatalogItem[]) => void' is not assignable to parameter of type '((value: CatalogItem | CatalogItem[]) => void | PromiseLike) | null | undefined'. Type '(items: CatalogItem[]) => void' is not assignable to type '(value: CatalogItem | CatalogItem[]) => void | PromiseLike'. Types of parameters 'items' and 'value' are incompatible. Type 'CatalogItem | CatalogItem[]' is not assignable to type 'CatalogItem[]'. Type 'CatalogItem' is not assignable to type 'CatalogItem[]'.

ERROR in ./src/home.tsx (94,65): error TS2605: JSX element type 'Link' is not a constructor function for JSX elements. Types of property 'render' are incompatible. Type '() => ReactNode' is not assignable to type '{ (): ReactNode; (): false | Element | null; }'. Type 'ReactNode' is not assignable to type 'false | Element | null'. Type 'undefined' is not assignable to type 'false | Element | null'.

ERROR in ./src/home.tsx (111,21): error TS2605: JSX element type 'Link' is not a constructor function for JSX elements.

ERROR in ./src/home.tsx (112,66): error TS2605: JSX element type 'Link' is not a constructor function for JSX elements.