Rewrite amp-story-player CDN hosted script to the local build
Currently, importing a script with the CDN URL (https://cdn.ampproject.org/...) in a local sample will be rewritten by the build system so you get the local build of the library. This is not the case for the non-AMP version of the amp-story-player.
Steps to repro:
- Open a local sample with the amp-story-player and import it using the
<script async src="https://cdn.ampproject.org/amp-story-player-v0.js"></script>
Expected: Getting the local build. Actual: Getting the CDN hosted build.
More context
Today, we need to specifically write <script async src="../../dist/amp-story-player.js"></script>, which is unlike other extensions and brings confusion in local development.
The non-AMP version of the player is located in src/, specifically here: https://github.com/ampproject/amphtml/blob/master/src/amp-story-player/amp-story-player.js
And here is where we define the minified name and location: https://github.com/ampproject/amphtml/blob/1e565fb911c045fba5a6e1fb9555b75f6c880529/build-system/compile/bundles.config.js#L158-L167
Is there something else we need to make it work? @ampproject/wg-infra @ampproject/wg-stories
cc @ampproject/wg-infra @rsimha do you know what we're missing here and why the CDN URL isn't rewritten to the local build one for this extension?
This issue has been automatically marked as stale because it has not had recent activity. It will be closed in 7 days if no further activity occurs. Thank you for your contributions.