Closed awmiii closed 6 years ago
Dear awmiii, have you tried fresh installation? Perhaps you could try to install it via npm? If nothing help please share your project with us so we could have a look at your source code.
Fresh install using Visual Studio 2017 Ent NPM 3.10.10 Node 6.11.5 Latest Service Fabric local install for development
New Project Service Fabric Application .Net Framework 4.6.2 Stateless ASP.Net Core Template ASP.Net Core 2.0 Angular Project Template
Removed bootstrap 3.3.7 from the project project built and functioned just fine.
But I added "angular-bootstrap-md": "^4.3.7" following your instructions using npm along with adjusting the config for Webpack as it compiles the src files.
When webpack compiles the files we get errors in angular bootstrap md files. I spent a lot of time getting all the npm packages from failing... I tried going backward as far as your project would allow me to go back with typescript thinking that may be the problem. It still fails.
Here is the output from the build and publish:
Restoring NuGet packages...
To prevent NuGet from restoring packages during build, open the Visual Studio Options dialog, click on the Package Manager node and uncheck 'Allow NuGet to download missing packages during build.'
1>------ Build started: Project: Market, Configuration: Debug x64 ------
2>------ Deploy started: Project: Market, Configuration: Debug x64 ------
2>Started executing script 'GetApplicationExistence'.
-------- Package started: Project: Market, Configuration: Debug x64 ------
2>Finished executing script 'GetApplicationExistence'.
2>Time elapsed: 00:00:05.4483657
Market.Web -> C:\Users\Trey\source\repos\Market\Market.Web\bin\x64\Debug\net462\win7-x64\Market.Web.exe
Market.Web@0.0.0 C:\Users\Trey\source\repos\Market\Market.Web
+-- karma@1.7.0
| -- lodash@3.10.1
-- karma-webpack@2.0.3
+-- async@0.9.2
+-- lodash@3.10.1
`-- source-map@0.1.43
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@^1.0.0 (node_modules\chokidar\node_modules\fsevents): npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.1.2: wanted {"os":"darwin","arch":"any"} (current: {"os":"win32","arch":"x64"}) Hash: 2e80e7f9ee4af05977135894342bc11638a05b3c Version: webpack 2.5.1 Child Hash: 2e80e7f9ee4af0597713 Time: 6643ms Asset Size Chunks Chunk Names 674f50d287a8c48dc19ba404d20fe713.eot 166 kB [emitted] 912ec66d7572ff821749319396470bde.svg 444 kB [emitted] [big] b06871f281fee6b241d60582ae9369b9.ttf 166 kB [emitted] vendor.js 69.8 kB 0 [emitted] vendor vendor.css 265 kB 0 [emitted] [big] vendor Child Hash: 5894342bc11638a05b3c Time: 6732ms Asset Size Chunks Chunk Names 674f50d287a8c48dc19ba404d20fe713.eot 166 kB [emitted] 912ec66d7572ff821749319396470bde.svg 444 kB [emitted] [big] b06871f281fee6b241d60582ae9369b9.ttf 166 kB [emitted] vendor.js 3.06 MB 0 [emitted] [big] vendor Hash: 408ab68a9d917000c3ed2af9d7a2f71d627e0ec3 Version: webpack 2.5.1 Child Hash: 408ab68a9d917000c3ed Time: 16090ms Asset Size Chunks Chunk Names main-client.js 532 kB 0 [emitted] [big] main-client Child Hash: 2af9d7a2f71d627e0ec3 Time: 15812ms Asset Size Chunks Chunk Names main-server.js 2.08 MB 0 [emitted] [big] main-server
ERROR in ./$$_gendir/~/angular-bootstrap-md/dropdown/dropdown-container.component.ngfactory.ts
Module parse failed: C:\Users\Trey\source\repos\Market\Market.Web\$$_gendir\node_modules\angular-bootstrap-md\dropdown\dropdown-container.component.ngfactory.ts Unexpected token (12:41)
You may need an appropriate loader to handle this file type.
| import * as i1 from 'angular-bootstrap-md/dropdown/dropdown-container.component';
| import * as i2 from 'angular-bootstrap-md/dropdown/dropdown.state';
| const styles_BsDropdownContainerComponent:any[] = ([] as any[]);
| export const RenderType_BsDropdownContainerComponent:i0.RendererType2 = i0.╔╡crt({encapsulation:2,
| styles:styles_BsDropdownContainerComponent,data:{}});
@ ./$$_gendir/ClientApp/app/app.module.server.ngfactory.ts 10:0-123
@ ./ClientApp/boot.server.ts
ERROR in ./$$_gendir/~/angular-bootstrap-md/modals/modalBackdrop.component.ngfactory.ts
Module parse failed: C:\Users\Trey\source\repos\Market\Market.Web\$$_gendir\node_modules\angular-bootstrap-md\modals\modalBackdrop.component.ngfactory.ts Unexpected token (11:35)
You may need an appropriate loader to handle this file type.
| import * as i0 from '@angular/core';
| import * as i1 from 'angular-bootstrap-md/modals/modalBackdrop.component';
| const styles_ModalBackdropComponent:any[] = ([] as any[]);
| export const RenderType_ModalBackdropComponent:i0.RendererType2 = i0.╔╡crt({encapsulation:2,
| styles:styles_ModalBackdropComponent,data:{}});
@ ./$$_gendir/ClientApp/app/app.module.server.ngfactory.ts 11:0-116
@ ./ClientApp/boot.server.ts
ERROR in ./$$_gendir/~/angular-bootstrap-md/modals/modalContainer.component.ngfactory.ts
Module parse failed: C:\Users\Trey\source\repos\Market\Market.Web\$$_gendir\node_modules\angular-bootstrap-md\modals\modalContainer.component.ngfactory.ts Unexpected token (13:36)
You may need an appropriate loader to handle this file type.
| import * as i2 from 'angular-bootstrap-md/modals/modal.options';
| import * as i3 from 'angular-bootstrap-md/modals/modal.service';
| const styles_ModalContainerComponent:any[] = ([] as any[]);
| export const RenderType_ModalContainerComponent:i0.RendererType2 = i0.╔╡crt({encapsulation:2,
| styles:styles_ModalContainerComponent,data:{}});
@ ./$$_gendir/ClientApp/app/app.module.server.ngfactory.ts 12:0-117
@ ./ClientApp/boot.server.ts
ERROR in ./$$_gendir/~/angular-bootstrap-md/tooltip/tooltip.component.ngfactory.ts
Module parse failed: C:\Users\Trey\source\repos\Market\Market.Web\$$_gendir\node_modules\angular-bootstrap-md\tooltip\tooltip.component.ngfactory.ts Unexpected token (12:38)
You may need an appropriate loader to handle this file type.
| import * as i1 from 'angular-bootstrap-md/tooltip/tooltip.component';
| import * as i2 from 'angular-bootstrap-md/tooltip/tooltip.service';
| const styles_TooltipContainerComponent:any[] = ([] as any[]);
| export const RenderType_TooltipContainerComponent:i0.RendererType2 = i0.╔╡crt({encapsulation:2,
| styles:styles_TooltipContainerComponent,data:{}});
@ ./$$_gendir/ClientApp/app/app.module.server.ngfactory.ts 13:0-111
@ ./ClientApp/boot.server.ts
ERROR in ./$$_gendir/~/angular-bootstrap-md/popover/popover-container.component.ngfactory.ts
Module parse failed: C:\Users\Trey\source\repos\Market\Market.Web\$$_gendir\node_modules\angular-bootstrap-md\popover\popover-container.component.ngfactory.ts Unexpected token (13:38)
You may need an appropriate loader to handle this file type.
| import * as i2 from 'angular-bootstrap-md/popover/popover-container.component';
| import * as i3 from 'angular-bootstrap-md/popover/popover.config';
| const styles_PopoverContainerComponent:any[] = ([] as any[]);
| export const RenderType_PopoverContainerComponent:i0.RendererType2 = i0.╔╡crt({encapsulation:2,
| styles:styles_PopoverContainerComponent,data:{}});
@ ./$$_gendir/ClientApp/app/app.module.server.ngfactory.ts 14:0-121
@ ./ClientApp/boot.server.ts
ERROR in ./~/angular-bootstrap-md/dropdown/dropdown.state.ts
Module parse failed: C:\Users\Trey\source\repos\Market\Market.Web\node_modules\angular-bootstrap-md\dropdown\dropdown.state.ts Unexpected character '@' (4:0)
You may need an appropriate loader to handle this file type.
| import { BsComponentRef } from '../utils/component-loader/bs-component-ref.class';
|
| @Injectable()
| export class BsDropdownState {
| direction: 'down' | 'up' = 'down';
@ ./$$_gendir/ClientApp/app/app.module.server.ngfactory.ts 23:0-68
@ ./ClientApp/boot.server.ts
ERROR in ./~/angular-bootstrap-md/modals/modal.service.ts
Module parse failed: C:\Users\Trey\source\repos\Market\Market.Web\node_modules\angular-bootstrap-md\modals\modal.service.ts Unexpected character '@' (9:0)
You may need an appropriate loader to handle this file type.
| import { MDBModalRef, ClassName, modalConfigDefaults, ModalOptions, TransitionDurations } from './modal.options';
|
| @Injectable()
| export class MDBModalService {
| // constructor props
@ ./$$_gendir/ClientApp/app/app.module.server.ngfactory.ts 24:0-65
@ ./ClientApp/boot.server.ts
ERROR in ./~/angular-bootstrap-md/tooltip/tooltip.service.ts
Module parse failed: C:\Users\Trey\source\repos\Market\Market.Web\node_modules\angular-bootstrap-md\tooltip\tooltip.service.ts Unexpected character '@' (4:0)
You may need an appropriate loader to handle this file type.
|
| /** Default values provider for tooltip */
| @Injectable()
| export class TooltipConfig {
| /** tooltip placement, supported positions: 'top', 'bottom', 'left', 'right' */
@ ./$$_gendir/ClientApp/app/app.module.server.ngfactory.ts 25:0-68
@ ./ClientApp/boot.server.ts
ERROR in ./~/angular-bootstrap-md/popover/popover.config.ts
Module parse failed: C:\Users\Trey\source\repos\Market\Market.Web\node_modules\angular-bootstrap-md\popover\popover.config.ts Unexpected character '@' (9:1)
You may need an appropriate loader to handle this file type.
| * popovers used in the application.
| */
| @Injectable()
| export class PopoverConfig {
| /**
@ ./$$_gendir/ClientApp/app/app.module.server.ngfactory.ts 26:0-67
@ ./ClientApp/boot.server.ts
ERROR in ./~/angular-bootstrap-md/dropdown/dropdown.module.ts
Module parse failed: C:\Users\Trey\source\repos\Market\Market.Web\node_modules\angular-bootstrap-md\dropdown\dropdown.module.ts Unexpected character '@' (13:0)
You may need an appropriate loader to handle this file type.
| import { BsDropdownState } from './dropdown.state';
|
| @NgModule({
| declarations: [
| BsDropdownMenuDirective,
@ ./$$_gendir/ClientApp/app/app.module.server.ngfactory.ts 39:0-69
@ ./ClientApp/boot.server.ts
ERROR in ./~/angular-bootstrap-md/modals/modal.module.ts
Module parse failed: C:\Users\Trey\source\repos\Market\Market.Web\node_modules\angular-bootstrap-md\modals\modal.module.ts Unexpected character '@' (10:0)
You may need an appropriate loader to handle this file type.
| import { MDBModalService } from './modal.service';
|
| @NgModule({
| declarations: [ModalBackdropComponent, ModalDirective, ModalContainerComponent],
| exports: [ModalBackdropComponent, ModalDirective],
@ ./$$_gendir/ClientApp/app/app.module.server.ngfactory.ts 43:0-64
@ ./ClientApp/boot.server.ts
ERROR in ./~/angular-bootstrap-md/tooltip/tooltip.module.ts
Module parse failed: C:\Users\Trey\source\repos\Market\Market.Web\node_modules\angular-bootstrap-md\tooltip\tooltip.module.ts Unexpected character '@' (9:0)
You may need an appropriate loader to handle this file type.
| import { PositioningService } from '../utils/positioning';
|
| @NgModule({
| imports: [CommonModule],
| declarations: [TooltipDirective, TooltipContainerComponent],
@ ./$$_gendir/ClientApp/app/app.module.server.ngfactory.ts 44:0-67
@ ./ClientApp/boot.server.ts
ERROR in ./~/angular-bootstrap-md/popover/popover.module.ts
Module parse failed: C:\Users\Trey\source\repos\Market\Market.Web\node_modules\angular-bootstrap-md\popover\popover.module.ts Unexpected character '@' (10:0)
You may need an appropriate loader to handle this file type.
| import { PopoverContainerComponent } from './popover-container.component';
|
| @NgModule({
| imports: [CommonModule],
| declarations: [PopoverDirective, PopoverContainerComponent],
@ ./$$_gendir/ClientApp/app/app.module.server.ngfactory.ts 45:0-67
@ ./ClientApp/boot.server.ts
ERROR in ./~/angular-bootstrap-md/index.ts
Module parse failed: C:\Users\Trey\source\repos\Market\Market.Web\node_modules\angular-bootstrap-md\index.ts Unexpected character '@' (78:0)
You may need an appropriate loader to handle this file type.
| ];
|
| @NgModule({
| imports: [
| ButtonsModule,
@ ./$$_gendir/ClientApp/app/app.module.server.ngfactory.ts 46:0-50
@ ./ClientApp/boot.server.ts
ERROR in ./~/angular-bootstrap-md/dropdown/dropdown.config.ts
Module parse failed: C:\Users\Trey\source\repos\Market\Market.Web\node_modules\angular-bootstrap-md\dropdown\dropdown.config.ts Unexpected character '@' (4:0)
You may need an appropriate loader to handle this file type.
|
| /** Default dropdown configuration */
| @Injectable()
| export class BsDropdownConfig {
| /** default dropdown auto closing behavior */
@ ./$$_gendir/ClientApp/app/app.module.server.ngfactory.ts 51:0-69
@ ./ClientApp/boot.server.ts
ERROR in ./~/angular-bootstrap-md/carousel/carousel.config.ts
Module parse failed: C:\Users\Trey\source\repos\Market\Market.Web\node_modules\angular-bootstrap-md\carousel\carousel.config.ts Unexpected character '@' (3:0)
You may need an appropriate loader to handle this file type.
| import { Injectable } from '@angular/core';
|
| @Injectable()
| export class CarouselConfig {
| /** Default interval of auto changing of slides */
@ ./$$_gendir/ClientApp/app/app.module.server.ngfactory.ts 20:0-69
@ ./ClientApp/boot.server.ts
ERROR in ./~/angular-bootstrap-md/carousel/carousel.module.ts
Module parse failed: C:\Users\Trey\source\repos\Market\Market.Web\node_modules\angular-bootstrap-md\carousel\carousel.module.ts Unexpected character '@' (8:0)
You may need an appropriate loader to handle this file type.
| import { CarouselConfig } from './carousel.config';
|
| @NgModule({
| imports: [CommonModule],
| declarations: [SlideComponent, CarouselComponent],
@ ./$$_gendir/ClientApp/app/app.module.server.ngfactory.ts 40:0-69
@ ./ClientApp/boot.server.ts
ERROR in ./~/angular-bootstrap-md/buttons/buttons.module.ts
Module parse failed: C:\Users\Trey\source\repos\Market\Market.Web\node_modules\angular-bootstrap-md\buttons\buttons.module.ts Unexpected character '@' (6:0)
You may need an appropriate loader to handle this file type.
| import { ButtonRadioDirective } from './radio.directive';
|
| @NgModule({
| declarations: [ButtonCheckboxDirective, ButtonRadioDirective],
| exports: [ButtonCheckboxDirective, ButtonRadioDirective]
@ ./$$_gendir/ClientApp/app/app.module.server.ngfactory.ts 35:0-67
@ ./ClientApp/boot.server.ts
ERROR in ./~/angular-bootstrap-md/ripple/ripple.module.ts
Module parse failed: C:\Users\Trey\source\repos\Market\Market.Web\node_modules\angular-bootstrap-md\ripple\ripple.module.ts Unexpected character '@' (4:0)
You may need an appropriate loader to handle this file type.
| import { RippleDirective } from './ripple-effect.directive';
|
| @NgModule({
| declarations: [RippleDirective],
| exports: [RippleDirective]
@ ./$$_gendir/ClientApp/app/app.module.server.ngfactory.ts 36:0-65
@ ./ClientApp/boot.server.ts
ERROR in ./~/angular-bootstrap-md/inputs/active.module.ts
Module parse failed: C:\Users\Trey\source\repos\Market\Market.Web\node_modules\angular-bootstrap-md\inputs\active.module.ts Unexpected character '@' (6:0)
You may need an appropriate loader to handle this file type.
| import { InputValidateDirective } from './input-validate.directive';
|
| @NgModule({
| declarations: [ActiveDirective, EqualValidatorDirective, InputValidateDirective],
| exports: [ActiveDirective, EqualValidatorDirective, InputValidateDirective]
@ ./$$_gendir/ClientApp/app/app.module.server.ngfactory.ts 37:0-65
@ ./ClientApp/boot.server.ts
ERROR in ./~/angular-bootstrap-md/navbars/navbar.module.ts
Module parse failed: C:\Users\Trey\source\repos\Market\Market.Web\node_modules\angular-bootstrap-md\navbars\navbar.module.ts Unexpected character '@' (5:0)
You may need an appropriate loader to handle this file type.
| import { NavbarComponent } from './navbar.component';
|
| @NgModule({
| imports: [CommonModule],
| declarations: [NavbarComponent],
@ ./$$_gendir/ClientApp/app/app.module.server.ngfactory.ts 38:0-66
@ ./ClientApp/boot.server.ts
ERROR in ./~/angular-bootstrap-md/charts/chart.module.ts
Module parse failed: C:\Users\Trey\source\repos\Market\Market.Web\node_modules\angular-bootstrap-md\charts\chart.module.ts Unexpected character '@' (5:0)
You may need an appropriate loader to handle this file type.
| import { BaseChartDirective } from './chart.directive';
|
| @NgModule({
| declarations: [
| BaseChartDirective
@ ./$$_gendir/ClientApp/app/app.module.server.ngfactory.ts 41:0-64
@ ./ClientApp/boot.server.ts
ERROR in ./~/angular-bootstrap-md/collapse/collapse.module.ts
Module parse failed: C:\Users\Trey\source\repos\Market\Market.Web\node_modules\angular-bootstrap-md\collapse\collapse.module.ts Unexpected character '@' (4:0)
You may need an appropriate loader to handle this file type.
| import { CollapseDirective } from './collapse.directive';
|
| @NgModule({
| declarations: [CollapseDirective],
| exports: [CollapseDirective]
@ ./$$_gendir/ClientApp/app/app.module.server.ngfactory.ts 42:0-69
@ ./ClientApp/boot.server.ts
ERROR in ./~/angular-bootstrap-md/utils/positioning/positioning.service.ts
Module parse failed: C:\Users\Trey\source\repos\Market\Market.Web\node_modules\angular-bootstrap-md\utils\positioning\positioning.service.ts Unexpected token (4:7)
You may need an appropriate loader to handle this file type.
| import { positionElements } from './ng-positioning';
|
| export interface PositioningOptions {
| /** The DOM element, ElementRef, or a selector string of an element which will be moved */
| element?: HTMLElement | ElementRef | string;
@ ./$$_gendir/ClientApp/app/app.module.server.ngfactory.ts 21:0-82
@ ./ClientApp/boot.server.ts
ERROR in ./~/angular-bootstrap-md/utils/component-loader/component-loader.factory.ts
Module parse failed: C:\Users\Trey\source\repos\Market\Market.Web\node_modules\angular-bootstrap-md\utils\component-loader\component-loader.factory.ts Unexpected character '@' (8:0)
You may need an appropriate loader to handle this file type.
| import { PositioningService } from '../positioning';
|
| @Injectable()
| export class ComponentLoaderFactory {
|
@ ./$$_gendir/ClientApp/app/app.module.server.ngfactory.ts 22:0-92
@ ./ClientApp/boot.server.ts
C:\Users\Trey\source\repos\Market\Market.Web\Market.Web.csproj(50,5): error MSB3073: The command "node node_modules/webpack/bin/webpack.js --env.prod" exited with code 2.
Done building project "Market.Web.csproj" -- FAILED.
Market -> C:\Users\Trey\source\repos\Market\Market\pkg\Debug
-------- Package: Project: Market succeeded, Time elapsed: 00:00:48.3486399 --------
2>Started executing script 'Deploy-FabricApplication.ps1'.
2>. 'C:\Users\Trey\source\repos\Market\Market\Scripts\Deploy-FabricApplication.ps1' -ApplicationPackagePath 'C:\Users\Trey\source\repos\Market\Market\pkg\Debug' -PublishProfileFile 'C:\Users\Trey\source\repos\Market\Market\PublishProfiles\Local.5Node.xml' -DeployOnly:$true -ApplicationParameter:@{} -UnregisterUnusedApplicationVersionsAfterUpgrade $false -OverrideUpgradeBehavior 'None' -OverwriteBehavior 'Always' -SkipPackageValidation:$true -ErrorAction Stop
2>Copying application to image store...
2>Upload to Image Store succeeded
2>Registering application type...
2>Register-ServiceFabricApplicationType : The BuildLayout of the application in
2>C:\SfDevCluster\Data\ImageBuilderProxy\AppType\MarketType is invalid. Code is missing for service
2>Market.WebPkg.
2>At C:\Program Files\Microsoft SDKs\Service
2>Fabric\Tools\PSModule\ServiceFabricSDK\Publish-NewServiceFabricApplication.ps1:251 char:9
2>+ Register-ServiceFabricApplicationType -ApplicationPathInImage ...
2>+ ~~~~~~~~~~~~~
2> + CategoryInfo : InvalidOperation: (Microsoft.Servi...usterConnection:ClusterConnection) [Register-Servic
2> eFabricApplicationType], FabricException
2> + FullyQualifiedErrorId : RegisterApplicationTypeErrorId,Microsoft.ServiceFabric.Powershell.RegisterApplicationTyp
2> e
2>
2>Finished executing script 'Deploy-FabricApplication.ps1'.
2>Time elapsed: 00:00:22.1676804
2>The PowerShell script failed to execute.
========== Build: 1 succeeded, 0 failed, 1 up-to-date, 0 skipped ==========
========== Deploy: 0 succeeded, 1 failed, 0 skipped ==========
Here are the errors as seen in the Error list in Visual Studio
Severity Code Description Project File Line Suppression State
Error TS2345 (TS) Argument of type 'null' is not assignable to parameter of type 'ElementRef'. Market.Web (tsconfig project) C:\Users\Trey\source\repos\Market\Market.Web\node_modules\angular-bootstrap-md\modals\modal.service.ts 32 Active
Error TS2345 (TS) Argument of type 'null' is not assignable to parameter of type 'ElementRef'. Market.Web (tsconfig project) C:\Users\Trey\source\repos\Market\Market.Web\node_modules\angular-bootstrap-md\modals\modal.service.ts 156 Active
Error TS2345 (TS) Argument of type 'string | HTMLElement | ElementRef | undefined' is not assignable to parameter of type 'string | HTMLElement | ElementRef'.
Type 'undefined' is not assignable to type 'string | HTMLElement | ElementRef'. Market.Web (tsconfig project) C:\Users\Trey\source\repos\Market\Market.Web\node_modules\angular-bootstrap-md\utils\positioning\positioning.service.ts 41 Active
Error TS2345 (TS) Argument of type 'string | HTMLElement | ElementRef | undefined' is not assignable to parameter of type 'string | HTMLElement | ElementRef'.
Type 'undefined' is not assignable to type 'string | HTMLElement | ElementRef'. Market.Web (tsconfig project) C:\Users\Trey\source\repos\Market\Market.Web\node_modules\angular-bootstrap-md\utils\positioning\positioning.service.ts 42 Active
Error TS2345 (TS) Argument of type 'string | undefined' is not assignable to parameter of type 'string'.
Type 'undefined' is not assignable to type 'string'. Market.Web (tsconfig project) C:\Users\Trey\source\repos\Market\Market.Web\node_modules\angular-bootstrap-md\utils\positioning\positioning.service.ts 43 Active
Error TS2345 (TS) Argument of type 'string | undefined' is not assignable to parameter of type 'string'.
Type 'undefined' is not assignable to type 'string'. Market.Web (tsconfig project) C:\Users\Trey\source\repos\Market\Market.Web\node_modules\angular-bootstrap-md\utils\triggers.ts 58 Active
Error TS2345 (TS) Argument of type 'ValidationErrors | null' is not assignable to parameter of type '{}'.
Type 'null' is not assignable to type '{}'. Market.Web (tsconfig project) C:\Users\Trey\source\repos\Market\Market.Web\node_modules\angular-bootstrap-md\inputs\equal-validator.directive.ts 39 Active
Error TS7015 (TS) Element implicitly has an 'any' type because index expression is not of type 'number'. Market.Web (tsconfig project) C:\Users\Trey\source\repos\Market\Market.Web\node_modules\angular-bootstrap-md\inputs\input-validate.directive.ts 37 Active
Error TS7017 (TS) Element implicitly has an 'any' type because type 'PropertyDescriptor' has no index signature. Market.Web (tsconfig project) C:\Users\Trey\source\repos\Market\Market.Web\node_modules\angular-bootstrap-md\utils\decorators.ts 7 Active
Error TS7017 (TS) Element implicitly has an 'any' type because type 'PropertyDescriptor' has no index signature. Market.Web (tsconfig project) C:\Users\Trey\source\repos\Market\Market.Web\node_modules\angular-bootstrap-md\utils\decorators.ts 9 Active
Error TS7017 (TS) Element implicitly has an 'any' type because type 'PropertyDescriptor' has no index signature. Market.Web (tsconfig project) C:\Users\Trey\source\repos\Market\Market.Web\node_modules\angular-bootstrap-md\utils\decorators.ts 10 Active
Error TS7017 (TS) Element implicitly has an 'any' type because type 'PropertyDescriptor' has no index signature. Market.Web (tsconfig project) C:\Users\Trey\source\repos\Market\Market.Web\node_modules\angular-bootstrap-md\utils\decorators.ts 11 Active
Error TS7017 (TS) Element implicitly has an 'any' type because type 'PropertyDescriptor' has no index signature. Market.Web (tsconfig project) C:\Users\Trey\source\repos\Market\Market.Web\node_modules\angular-bootstrap-md\utils\decorators.ts 12 Active
Error TS2531 (TS) Object is possibly 'null'. Market.Web (tsconfig project) C:\Users\Trey\source\repos\Market\Market.Web\node_modules\angular-bootstrap-md\inputs\equal-validator.directive.ts 38 Active
Error TS2531 (TS) Object is possibly 'null'. Market.Web (tsconfig project) C:\Users\Trey\source\repos\Market\Market.Web\node_modules\angular-bootstrap-md\inputs\input-validate.directive.ts 37 Active
Error TS2531 (TS) Object is possibly 'null'. Market.Web (tsconfig project) C:\Users\Trey\source\repos\Market\Market.Web\node_modules\angular-bootstrap-md\utils\component-loader\component-loader.class.ts 133 Active
Error TS2532 (TS) Object is possibly 'undefined'. Market.Web (tsconfig project) C:\Users\Trey\source\repos\Market\Market.Web\node_modules\angular-bootstrap-md\inputs\input-validate.directive.ts 37 Active
Error TS2532 (TS) Object is possibly 'undefined'. Market.Web (tsconfig project) C:\Users\Trey\source\repos\Market\Market.Web\node_modules\angular-bootstrap-md\utils\component-loader\component-loader.class.ts 99 Active
Error TS2532 (TS) Object is possibly 'undefined'. Market.Web (tsconfig project) C:\Users\Trey\source\repos\Market\Market.Web\node_modules\angular-bootstrap-md\utils\component-loader\component-loader.class.ts 100 Active
Error TS2532 (TS) Object is possibly 'undefined'. Market.Web (tsconfig project) C:\Users\Trey\source\repos\Market\Market.Web\node_modules\angular-bootstrap-md\utils\component-loader\component-loader.class.ts 215 Active
Error TS2532 (TS) Object is possibly 'undefined'. Market.Web (tsconfig project) C:\Users\Trey\source\repos\Market\Market.Web\node_modules\angular-bootstrap-md\utils\component-loader\component-loader.class.ts 216 Active
Error TS2365 (TS) Operator '===' cannot be applied to types 'false | undefined' and '"static"'. Market.Web (tsconfig project) C:\Users\Trey\source\repos\Market\Market.Web\node_modules\angular-bootstrap-md\modals\modal.service.ts 58 Active
Error TS2322 (TS) Type 'null' is not assignable to type 'boolean'. Market.Web (tsconfig project) C:\Users\Trey\source\repos\Market\Market.Web\node_modules\angular-bootstrap-md\dropdown\dropdown-toggle.directive.ts 14 Active
Error TS2322 (TS) Type 'null' is not assignable to type 'ComponentRef
Error The PowerShell script failed to execute. See the Output window for details. Market 0
Dear @awmiii thank you for the detailed feedback. We cannot reproduce it on our side. Could you please also provide us with exact steps to reproduce including command lines which you used? Thanks!
Visual Studio 2017 Ent NPM 3.10.10 Node 6.11.5
Latest Service Fabric local install for development (did this with service fabric and without) so that isn't an issue.
New Project Service Fabric Application .Net Framework 4.6.2 Stateless ASP.Net Core Template ASP.Net Core 2.0 Angular Project Template
1.Edited webpack.config.vendor.js
removed bootstrap and jquery from the config
also remove bootstrap from package.json 4 . uninstalled the dependency of bootstrap from npm
from Package Manager Console cd ... to project directory npm install (to check for errors) only one warning about an optional package fsevents
node node_modules/webpack/bin/webpack.js --config webpack.config.vendor.js --env.prod Ctrl f5 to run project
produces error in boot.server.ts I fix issue using by changing //const zone = moduleRef.injector.get(NgZone); const zone: NgZone = moduleRef.injector.get(NgZone);
I deleted the "dist" folder in wwwroot to make the project compile the files again. Ctrl f5 to run project Project runs fine without bootstrap or jquery
stop project ....Use instructions from https://www.npmjs.com/package/angular-bootstrap-md to install angular-bootstrap-md as applied to my project. I skip the angular-cli part being I'm not using that. Then: npm i angular-bootstrap-md --save (to install) npm i chart.js@2.5.0 --save npm i hammerjs@2.0 --save npm i font-awesome@4.7 --save npm install @agm/core --save
I deleted the "dist" folder in wwwroot to make the project compile the files again. Ctrl f5 to run project Runs fine... now lets introduce angular-bootstrap-md into the app module.
edit app.module.server.ts
import { NgModule, NO_ERRORS_SCHEMA } from '@angular/core'; import { MDBBootstrapModule } from 'angular-bootstrap-md'; import { ServerModule } from '@angular/platform-server'; import { AppModuleShared } from './app.module.shared'; import { AppComponent } from './components/app/app.component';
@NgModule({ bootstrap: [ AppComponent ], imports: [ MDBBootstrapModule.forRoot(), ServerModule, AppModuleShared ], schemas: [NO_ERRORS_SCHEMA] }) export class AppModule { }
all related to null, void, undefinded
Hope this is enough to show you the problem... typescript is used to compile and the typescript errors makes vs2017 and webpack unhappy. Maybe you know what I can do to work around the issue.
I continued working on adding scss and css files to the project successfully using webpack, but it's kind of pointless if I can't get past the current errors.
I resolved the issue. I'll post a solution later.
Dear @awmiii could you please share your solution so that more people could benefit from it?
Hi @awmiii , when you have time, please share your information on how you resolved this issue. kind regards, Anders.
Dear @awmiii please share your solution. For now - closing the issue.
@anders74 @awmiii What did you do to resolve the issue?
Hello all, we have just added tutorial on how to use MDB along with .NET & ASP : https://mdbootstrap.com/angular/5min-quickstart/
We have corrected this error by modifying webpack.config.js to include angular-bootstrap-md ts files to the list of files to be loaded by the TS transpiler:
module: {
rules: [
{
test: /\.ts$/,
include: [
/ClientApp/,
/angular-bootstrap-md/
],
use: isDevBuild ? ['awesome-typescript-loader?silent=true', 'angular2-template-loader', 'angular2-router-loader'] : '@ngtools/webpack'
},
]
},
Hope this helps
I have added angular-bootstrap-md to an existing angular site. I've included everything using npm and have followed your instructions. I've spent days working on trying to debug issues, but have come the the place where all the .ts files in angular-bootstrap-md folder have type script errors and will not build in Visual Studio 2017. Webpack is trying to compile the files but due to the errors it fails. HELP please.