Orchard - Can't find the Resource defined in ResourceManifest.cs
Posted
by
mlang
on Stack Overflow
See other posts from Stack Overflow
or by mlang
Published on 2013-06-25T18:17:43Z
Indexed on
2013/06/26
4:21 UTC
Read the original article
Hit count: 254
asp.net-mvc
|orchardcms
I have a custom there, where I try to require some of my css and js files via the ResourceManifest.cs file - I keep into running a quite weird issue tough.
I get the following error:
a 'script' named 'FoundationScript' could not be found
This is my ResourceManifest.cs:
using Orchard.UI.Resources;
namespace Themes.TestTheme
{
public class ResourceManifest : IResourceManifestProvider
{
public void BuildManifest(ResourceManifestBuilder builder)
{
var manifest = builder.Add();
manifest.DefineStyle("Foundation").SetUrl("foundation.min.css");
manifest.DefineScript("FoundationScript").SetUrl("foundation.min.js");
}
}
}
In the Layout.cshtml, I have following:
@{
Script.Require("ShapesBase");
Script.Require("FoundationScript");
Style.Include("site.css");
Style.Require("Foundation");
}
What am I missing here?
© Stack Overflow or respective owner