This repository was archived by the owner on Jan 23, 2020. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
This repository was archived by the owner on Jan 23, 2020. It is now read-only.
URL Design #3
Copy link
Copy link
Open
Description
In the prototypes made so far, a URL structure has been loosely determined with some but not a lot of thought. The following lays out the URLs that are currently in use in the prototype.
1. A global published module's immutable URLs
http://:assetServerUrl:port/:org/pkg/:pkgName/:version/index.js
http://:assetServerUrl:port/:org/pkg/:pkgName/:version/index.js.mapWhere:
:orgis the name of your organisation:pkgNameis the name of the package on npm:versionis the version of the package on npm
Example:
http://localhost:4001/finn/pkg/react/16.8.6/index.js
http://localhost:4001/finn/pkg/react/16.8.6/index.js.map2. A module alias' modifiable URL
http://:assetServerUrl:port/:org/alias/:pkgName/:alias/index.js
http://:assetServerUrl:port/:org/alias/:pkgName/:alias/index.js.mapWhere:
:orgis the name of your organisation:pkgNameis the name of the package on npm:aliasis the alias that you have assigned to the package eg.^16
Example:
http://localhost:4001/finn/alias/react/^16/index.js
http://localhost:4001/finn/alias/react/^16/index.js.map3. A modifiable import map file
http://:assetServerUrl:port/:org/map/jsWhere:
:orgis the name of your organisation
Example:
http://localhost:4001/finn/map/js4. An app's published assets
http://:assetServerUrl:port/:org/bundle/:appName/:version/index.js
http://:assetServerUrl:port>/:org/bundle/:appName/:version/index.js.mapWhere:
:orgis the name of your organisation:appNameis the name of your app:versionis the version of your assets being published
Example:
http://:assetServerUrl:port/finn/bundle/my-cool-app/1.0.0/index.js
http://:assetServerUrl:port/finn/bundle/my-cool-app/1.0.0/index.js.map
http://:assetServerUrl:port/finn/bundle/my-cool-app/1.0.0/fallback.js // ie11
http://:assetServerUrl:port/finn/bundle/my-cool-app/1.0.0/fallback.js.mapMetadata
Metadata
Assignees
Labels
No labels