# Ember prepends application name in the script tag in production environment

**URL:** <https://discuss.emberjs.com/t/ember-prepends-application-name-in-the-script-tag-in-production-environment/16484>\
**Category:** Questions\
**Created:** [April 24, 2019, 8:34pm UTC](https://discuss.emberjs.com/t/ember-prepends-application-name-in-the-script-tag-in-production-environment/16484 "2019-04-24T20:34:43Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![nullpointer](https://sea1.discourse-cdn.com/flex019/user_avatar/discuss.emberjs.com/nullpointer/32/16445_2.png) [@nullpointer](https://discuss.emberjs.com/u/nullpointer)\
**Post date:** [April 24, 2019, 8:34pm UTC](https://discuss.emberjs.com/t/ember-prepends-application-name-in-the-script-tag-in-production-environment/16484/1 "2019-04-24T20:34:43Z")

</div>

I am trying to build my application in production environment, which seems fine. But as soon as I access the application, I get the following errors in the console:

**Error parsing ‘integrity’ attribute. The specified hash algorithm must be one of ‘sha256’, ‘sha384’, or ‘sha512’.**

The hash seems fine, the problem is that the integrity attributes is like:

`<script src="appname/path/assets/filename.js" integrity="appname/path/sha256...."></script>`

instead of:

`<script src="appname/path/assets/filename.js" integrity="sha256...."></script>`

I don’t really know why is it adding the name and the path in the first place, or where or how it’s configured.

I also added the type attribute, that also got prepended with **appname/path**

Can anyone please help me with the correct configuration for this?

---

<div class="post-metadata">

**Author:** ![ef4](https://sea1.discourse-cdn.com/flex019/user_avatar/discuss.emberjs.com/ef4/32/13470_2.png) [@ef4](https://discuss.emberjs.com/u/ef4)\
**Post date:** [April 25, 2019, 6:15pm UTC](https://discuss.emberjs.com/t/ember-prepends-application-name-in-the-script-tag-in-production-environment/16484/2 "2019-04-25T18:15:20Z")

</div>

It sounds like some addon has a bug and is modifying more than it intended to.

What does that script tag look like in your `app/index.html`? Does it have `integrity=""` or something different?

Are you customizing any asset paths in the arguments to `new EmberApp` in ember-cli-build.js?

---

<div class="post-metadata">

**Author:** ![nullpointer](https://sea1.discourse-cdn.com/flex019/user_avatar/discuss.emberjs.com/nullpointer/32/16445_2.png) [@nullpointer](https://discuss.emberjs.com/u/nullpointer)\
**Post date:** [April 25, 2019, 6:21pm UTC](https://discuss.emberjs.com/t/ember-prepends-application-name-in-the-script-tag-in-production-environment/16484/3 "2019-04-25T18:21:44Z")

</div>

The script tag in **index.html** looks like:

`<script src="assets/filename.js"></script>`

I am not putting the **integrity** attribute, it gets added when I build in production mode.

Not customizing any asset paths either.

Thanks.

---

<div class="post-metadata">

**Author:** ![ef4](https://sea1.discourse-cdn.com/flex019/user_avatar/discuss.emberjs.com/ef4/32/13470_2.png) [@ef4](https://discuss.emberjs.com/u/ef4)\
**Post date:** [April 26, 2019, 7:30pm UTC](https://discuss.emberjs.com/t/ember-prepends-application-name-in-the-script-tag-in-production-environment/16484/4 "2019-04-26T19:30:15Z")

</div>

Hmm, I think this is worth filing a bug on [Issues · ember-cli/ember-cli · GitHub](https://github.com/ember-cli/ember-cli/issues)

In the meantime you can disable this feature by removing ember-cli-sri from package.json.
