Open muuki88 opened 10 years ago
I think that I might just remove that functionality because it is pretty brittle. Here is what you can use instead:
<script>
@play.api.Play.current.configuration.getString("assets.url").fold {
@Html(org.webjars.RequireJS.getSetupJavaScript(routes.WebJarAssets.at("").url))
} { assetsUrl =>
@Html(org.webjars.RequireJS.getSetupJavaScript(StaticWebJarAssets.url(""), routes.WebJarAssets.at("").url))
}
</script>
<script data-main="@routes.Assets.versioned("javascripts/app.js")" src="@StaticWebJarAssets.url(WebJarAssets.locate("require.min.js"))"></script>
From: https://github.com/jamesward/salesforce-webhook-creator/blob/master/app/views/app.scala.html
LMKWYT
Webjars-play only supports the
Assets.at
route (located in the nastyReflection).If I have an assets route like this
Results in an
InvocationTargetException
, because theat
method is not there.