Wednesday, 24 May 2017

Failed to load resource?

I have a ASP.NET Core 1.1 where I have followed this guide :

https://www.youtube.com/watch?v=HB6ftmxKzL8

I do however not get the Angular Module to run, its just stating "Loading". I can see in the webdev tool that some resources could not load(404)

http://localhost:44343/System.config.js http://localhost:44343/node_modules/core-js/client/shim.js http://localhost:44343/node_modules/zone.js/dist/zone.js http://localhost:44343/node_modules/systemjs/dist/system.src.js http://localhost:44343/System.config.js http://localhost:44343/

To activate Facebook login I hade to activate SSL but this is switched off again. This is how my Startup.Configure looks like :

public void Configure(IApplicationBuilder app, IHostingEnvironment env, ILoggerFactory loggerFactory)
        {
            loggerFactory.AddConsole(Configuration.GetSection("Logging"));
            loggerFactory.AddDebug();

            if (env.IsDevelopment())
            {
                app.UseDeveloperExceptionPage();
                app.UseDatabaseErrorPage();
                app.UseBrowserLink();
            }
            else
            {
                app.UseExceptionHandler("/Home/Error");
            }

            app.UseStaticFiles();

            app.UseIdentity();

            // Add external authentication middleware below. To configure them please see https://go.microsoft.com/fwlink/?LinkID=532715

            //https://docs.microsoft.com/sv-se/aspnet/core/security/authentication/social/facebook-logins
            app.UseFacebookAuthentication(new FacebookOptions()
            {
                AppId = Configuration["Authentication:Facebook:AppId"],
                AppSecret = Configuration["Authentication:Facebook:AppSecret"]
            });

            app.UseMvc(routes =>
            {
                routes.MapRoute(
                    name: "default",
                    template: "{controller=Home}/{action=Index}/{id?}");
            });
        }

The files do exists but they is placed under node_modules instead of under thw wwwroot is?



via Banshee

No comments:

Post a Comment