how to solve The NPM script 'start' exited without indicating that the Angular CLI
i am facing this error please help me this when i publish my app in IIS with angularjs please help me how to solve this error iam using .net core 2.1 and angularjs . In visual studio working fine I am facing this error in IIS
services.AddSpaStaticFiles(configuration =>
{
configuration.RootPath = "ClientApp/dist";
});
});
app.UseSpa(spa =>
{
// To learn more about options for serving an Angular SPA from ASP.NET Core,
// see https://go.microsoft.com/fwlink/?linkid=864501
spa.Options.SourcePath = "ClientApp";
if (env.IsDevelopment())
{
spa.UseAngularCliServer(npmScript: "start");
}
});
enter image description here
angular asp.net-core .net-core angular6
add a comment |
i am facing this error please help me this when i publish my app in IIS with angularjs please help me how to solve this error iam using .net core 2.1 and angularjs . In visual studio working fine I am facing this error in IIS
services.AddSpaStaticFiles(configuration =>
{
configuration.RootPath = "ClientApp/dist";
});
});
app.UseSpa(spa =>
{
// To learn more about options for serving an Angular SPA from ASP.NET Core,
// see https://go.microsoft.com/fwlink/?linkid=864501
spa.Options.SourcePath = "ClientApp";
if (env.IsDevelopment())
{
spa.UseAngularCliServer(npmScript: "start");
}
});
enter image description here
angular asp.net-core .net-core angular6
Angular 1.x? Or angular 2 and above?
– joey
Oct 10 at 3:45
angular6........
– JOhns
Oct 10 at 6:30
can you try compiling in visual studio code and view output?
– joey
Oct 11 at 3:33
add a comment |
i am facing this error please help me this when i publish my app in IIS with angularjs please help me how to solve this error iam using .net core 2.1 and angularjs . In visual studio working fine I am facing this error in IIS
services.AddSpaStaticFiles(configuration =>
{
configuration.RootPath = "ClientApp/dist";
});
});
app.UseSpa(spa =>
{
// To learn more about options for serving an Angular SPA from ASP.NET Core,
// see https://go.microsoft.com/fwlink/?linkid=864501
spa.Options.SourcePath = "ClientApp";
if (env.IsDevelopment())
{
spa.UseAngularCliServer(npmScript: "start");
}
});
enter image description here
angular asp.net-core .net-core angular6
i am facing this error please help me this when i publish my app in IIS with angularjs please help me how to solve this error iam using .net core 2.1 and angularjs . In visual studio working fine I am facing this error in IIS
services.AddSpaStaticFiles(configuration =>
{
configuration.RootPath = "ClientApp/dist";
});
});
app.UseSpa(spa =>
{
// To learn more about options for serving an Angular SPA from ASP.NET Core,
// see https://go.microsoft.com/fwlink/?linkid=864501
spa.Options.SourcePath = "ClientApp";
if (env.IsDevelopment())
{
spa.UseAngularCliServer(npmScript: "start");
}
});
enter image description here
angular asp.net-core .net-core angular6
angular asp.net-core .net-core angular6
asked Oct 9 at 15:13
JOhns
398
398
Angular 1.x? Or angular 2 and above?
– joey
Oct 10 at 3:45
angular6........
– JOhns
Oct 10 at 6:30
can you try compiling in visual studio code and view output?
– joey
Oct 11 at 3:33
add a comment |
Angular 1.x? Or angular 2 and above?
– joey
Oct 10 at 3:45
angular6........
– JOhns
Oct 10 at 6:30
can you try compiling in visual studio code and view output?
– joey
Oct 11 at 3:33
Angular 1.x? Or angular 2 and above?
– joey
Oct 10 at 3:45
Angular 1.x? Or angular 2 and above?
– joey
Oct 10 at 3:45
angular6........
– JOhns
Oct 10 at 6:30
angular6........
– JOhns
Oct 10 at 6:30
can you try compiling in visual studio code and view output?
– joey
Oct 11 at 3:33
can you try compiling in visual studio code and view output?
– joey
Oct 11 at 3:33
add a comment |
2 Answers
2
active
oldest
votes
npm script 'start' means, .Net Core is trying to call
ng serve
to
run the angular module in development env. So when your are hosting
your application in Azure/local or any other server, make sure you
have not deployed your application in Development environment.
"ASPNETCORE_ENVIRONMENT": "Development"
Change it to
"ASPNETCORE_ENVIRONMENT": "Production"
. Refer hereAfter you have deployed in production mode and still facing any other
errors. Try the following to find out the error. Comment out the
following code block in Startup.cs
//if (env.IsDevelopment())
// {
// spa.UseAngularCliServer(npmScript: "start");
// }
and deploy the application back in Development mode. You will get the real error message.
The variable can be changed in the ServiceManifest.xml file. By default it is not set.
add a comment |
public void Configure(IApplicationBuilder app, IHostingEnvironment env)
{
app.UseDeveloperExceptionPage();
app.UseHttpsRedirection();
app.UseStaticFiles();
app.UseAuthentication();
app.UseSpaStaticFiles();
app.UseMvc(routes =>
{
routes.MapRoute(
name: "default",
template: "{controller}/{action=Index}/{id?}");
routes.MapSpaFallbackRoute(
name: "spa-fallback",
defaults: new { controller = "Home", action = "Index" });
});
app.UseSpa(spa =>
{
// To learn more about options for serving an Angular SPA from ASP.NET Core,
// see https://go.microsoft.com/fwlink/?linkid=864501
spa.Options.SourcePath = "ClientApp";
if (env.IsDevelopment())
{
spa.UseAngularCliServer(npmScript: "start");
}
});
}
add a comment |
Your Answer
StackExchange.ifUsing("editor", function () {
StackExchange.using("externalEditor", function () {
StackExchange.using("snippets", function () {
StackExchange.snippets.init();
});
});
}, "code-snippets");
StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "1"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});
function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});
}
});
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f52724294%2fhow-to-solve-the-npm-script-start-exited-without-indicating-that-the-angular-c%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
2 Answers
2
active
oldest
votes
2 Answers
2
active
oldest
votes
active
oldest
votes
active
oldest
votes
npm script 'start' means, .Net Core is trying to call
ng serve
to
run the angular module in development env. So when your are hosting
your application in Azure/local or any other server, make sure you
have not deployed your application in Development environment.
"ASPNETCORE_ENVIRONMENT": "Development"
Change it to
"ASPNETCORE_ENVIRONMENT": "Production"
. Refer hereAfter you have deployed in production mode and still facing any other
errors. Try the following to find out the error. Comment out the
following code block in Startup.cs
//if (env.IsDevelopment())
// {
// spa.UseAngularCliServer(npmScript: "start");
// }
and deploy the application back in Development mode. You will get the real error message.
The variable can be changed in the ServiceManifest.xml file. By default it is not set.
add a comment |
npm script 'start' means, .Net Core is trying to call
ng serve
to
run the angular module in development env. So when your are hosting
your application in Azure/local or any other server, make sure you
have not deployed your application in Development environment.
"ASPNETCORE_ENVIRONMENT": "Development"
Change it to
"ASPNETCORE_ENVIRONMENT": "Production"
. Refer hereAfter you have deployed in production mode and still facing any other
errors. Try the following to find out the error. Comment out the
following code block in Startup.cs
//if (env.IsDevelopment())
// {
// spa.UseAngularCliServer(npmScript: "start");
// }
and deploy the application back in Development mode. You will get the real error message.
The variable can be changed in the ServiceManifest.xml file. By default it is not set.
add a comment |
npm script 'start' means, .Net Core is trying to call
ng serve
to
run the angular module in development env. So when your are hosting
your application in Azure/local or any other server, make sure you
have not deployed your application in Development environment.
"ASPNETCORE_ENVIRONMENT": "Development"
Change it to
"ASPNETCORE_ENVIRONMENT": "Production"
. Refer hereAfter you have deployed in production mode and still facing any other
errors. Try the following to find out the error. Comment out the
following code block in Startup.cs
//if (env.IsDevelopment())
// {
// spa.UseAngularCliServer(npmScript: "start");
// }
and deploy the application back in Development mode. You will get the real error message.
The variable can be changed in the ServiceManifest.xml file. By default it is not set.
npm script 'start' means, .Net Core is trying to call
ng serve
to
run the angular module in development env. So when your are hosting
your application in Azure/local or any other server, make sure you
have not deployed your application in Development environment.
"ASPNETCORE_ENVIRONMENT": "Development"
Change it to
"ASPNETCORE_ENVIRONMENT": "Production"
. Refer hereAfter you have deployed in production mode and still facing any other
errors. Try the following to find out the error. Comment out the
following code block in Startup.cs
//if (env.IsDevelopment())
// {
// spa.UseAngularCliServer(npmScript: "start");
// }
and deploy the application back in Development mode. You will get the real error message.
The variable can be changed in the ServiceManifest.xml file. By default it is not set.
edited Nov 20 at 7:17
Nick
1991111
1991111
answered Oct 10 at 17:21
Mathew Abraham
214
214
add a comment |
add a comment |
public void Configure(IApplicationBuilder app, IHostingEnvironment env)
{
app.UseDeveloperExceptionPage();
app.UseHttpsRedirection();
app.UseStaticFiles();
app.UseAuthentication();
app.UseSpaStaticFiles();
app.UseMvc(routes =>
{
routes.MapRoute(
name: "default",
template: "{controller}/{action=Index}/{id?}");
routes.MapSpaFallbackRoute(
name: "spa-fallback",
defaults: new { controller = "Home", action = "Index" });
});
app.UseSpa(spa =>
{
// To learn more about options for serving an Angular SPA from ASP.NET Core,
// see https://go.microsoft.com/fwlink/?linkid=864501
spa.Options.SourcePath = "ClientApp";
if (env.IsDevelopment())
{
spa.UseAngularCliServer(npmScript: "start");
}
});
}
add a comment |
public void Configure(IApplicationBuilder app, IHostingEnvironment env)
{
app.UseDeveloperExceptionPage();
app.UseHttpsRedirection();
app.UseStaticFiles();
app.UseAuthentication();
app.UseSpaStaticFiles();
app.UseMvc(routes =>
{
routes.MapRoute(
name: "default",
template: "{controller}/{action=Index}/{id?}");
routes.MapSpaFallbackRoute(
name: "spa-fallback",
defaults: new { controller = "Home", action = "Index" });
});
app.UseSpa(spa =>
{
// To learn more about options for serving an Angular SPA from ASP.NET Core,
// see https://go.microsoft.com/fwlink/?linkid=864501
spa.Options.SourcePath = "ClientApp";
if (env.IsDevelopment())
{
spa.UseAngularCliServer(npmScript: "start");
}
});
}
add a comment |
public void Configure(IApplicationBuilder app, IHostingEnvironment env)
{
app.UseDeveloperExceptionPage();
app.UseHttpsRedirection();
app.UseStaticFiles();
app.UseAuthentication();
app.UseSpaStaticFiles();
app.UseMvc(routes =>
{
routes.MapRoute(
name: "default",
template: "{controller}/{action=Index}/{id?}");
routes.MapSpaFallbackRoute(
name: "spa-fallback",
defaults: new { controller = "Home", action = "Index" });
});
app.UseSpa(spa =>
{
// To learn more about options for serving an Angular SPA from ASP.NET Core,
// see https://go.microsoft.com/fwlink/?linkid=864501
spa.Options.SourcePath = "ClientApp";
if (env.IsDevelopment())
{
spa.UseAngularCliServer(npmScript: "start");
}
});
}
public void Configure(IApplicationBuilder app, IHostingEnvironment env)
{
app.UseDeveloperExceptionPage();
app.UseHttpsRedirection();
app.UseStaticFiles();
app.UseAuthentication();
app.UseSpaStaticFiles();
app.UseMvc(routes =>
{
routes.MapRoute(
name: "default",
template: "{controller}/{action=Index}/{id?}");
routes.MapSpaFallbackRoute(
name: "spa-fallback",
defaults: new { controller = "Home", action = "Index" });
});
app.UseSpa(spa =>
{
// To learn more about options for serving an Angular SPA from ASP.NET Core,
// see https://go.microsoft.com/fwlink/?linkid=864501
spa.Options.SourcePath = "ClientApp";
if (env.IsDevelopment())
{
spa.UseAngularCliServer(npmScript: "start");
}
});
}
answered Oct 11 at 13:56
JOhns
398
398
add a comment |
add a comment |
Thanks for contributing an answer to Stack Overflow!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Some of your past answers have not been well-received, and you're in danger of being blocked from answering.
Please pay close attention to the following guidance:
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f52724294%2fhow-to-solve-the-npm-script-start-exited-without-indicating-that-the-angular-c%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Angular 1.x? Or angular 2 and above?
– joey
Oct 10 at 3:45
angular6........
– JOhns
Oct 10 at 6:30
can you try compiling in visual studio code and view output?
– joey
Oct 11 at 3:33