Skip to content
This repository has been archived by the owner on May 10, 2021. It is now read-only.

Problem with parcels dynamic imports #18

Open
elbotho opened this issue Jun 17, 2019 · 0 comments
Open

Problem with parcels dynamic imports #18

elbotho opened this issue Jun 17, 2019 · 0 comments
Assignees
Labels
enhancement New feature or request help wanted Extra attention is needed

Comments

@elbotho
Copy link

elbotho commented Jun 17, 2019

If I use the dynamic import (see here)
with the prerenderer the resulting script tags use absolute paths starting with http://localhost:8000

something like

import('./main').then(function(page) {
  // Render page
  page.render()
})

results in

<script async type="text/javascript" charset="utf-8" src="http://localhost:8000/main.5c28f114.js"></script>

I didn't find a way to force relative paths in parcel. Any ideas how I could solve this elegantly?
(atm. i use something like .replace('http://localhost:8000/','./')

@ABuffSeagull ABuffSeagull self-assigned this Jan 27, 2020
@ABuffSeagull ABuffSeagull added enhancement New feature or request help wanted Extra attention is needed labels Jan 27, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
enhancement New feature or request help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

2 participants