Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix esbuild if srcDir is different from the default #217

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

douglasward
Copy link
Contributor

If the srcDir in the elder.config.js is set to something other than src, then esbuild no longer works correctly. This pull request aims to fix this.

Everything seems to work fine (including hydration) except that the onMount svelte hook isn't called for the demo clock component and I can't work out why.

Copy link
Contributor

@nickreese nickreese left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me. Sorry for the delay. International moves are a bit of chaos and take a while to unwind.

@@ -29,7 +29,7 @@ const prepareFindSvelteComponent = ({ ssrFolder, rootDir, clientComponents: clie

// abs path first
if (nameFixed.includes(rootDirFixed)) {
const rel = windowsPathFix(path.relative(path.join(rootDirFixed, 'src'), name))
const rel = windowsPathFix(path.relative(path.join(rootDirFixed, srcDir.replace(rootDir, '')), name))
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For some reason I'm having a brain fart here. Can you confirm there.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants