Build error with v1.2.1: TypeError [ERR_INVALID_ARG_TYPE]: The "id" argument must be of type string. Received undefined
See original GitHub issueHello!
First of all, thank you so much for Elder.js! Really love working with it!!
Since I was excited about the new release, I decided to try it out. But I am getting an error during build:
TypeError [ERR_INVALID_ARG_TYPE]: The "id" argument must be of type string. Received undefined
Seems to be coming from the dynamic require of ssr (in src/utils/svelteComponent.ts):
// eslint-disable-next-line import/no-dynamic-require
const ssrReq = require(ssr);
Not sure if this is caused by something on my local machine or not. Any ideas what I can do to fix this?
(The error also occurs with a clean install of latest Elderjs/template btw…)
Issue Analytics
- State:
- Created 3 years ago
- Comments:6 (2 by maintainers)
Top Results From Across the Web
TypeError: The "id" argument must be of type string. Received ...
After running storybook-start or build-sb I get the following The error doesn't stop the execution and after a few seconds I get to...
Read more >The "id" argument must be of type string. Received type object
As I created my first app and run, I got this error. TypeError [ERR_INVALID_ARG_TYPE]: The " ...
Read more >npm err! the "from" argument must be of type string. received ...
I thought the error was telling me that path was undefined. When it fact it was saying the variables passed into path.join() were...
Read more >TypeError [ERR_INVALID_ARG_TYPE]: The "path" argument ...
Big bad error: ERR_INVALID_ARG_TYPE { TypeError [ERR_INVALID_ARG_TYPE]: The "id" argument must be of type string. Received type undefined at validateString ...
Read more >The "url" argument must be of type string. Received undefined ...
I got this error while seed the data from nodejs to mongo DB.
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
You need restart the dev
I was getting this issue because I imported a component that I wanted to hydrate-client without matching the name of the .svelte file. For example:
import Functionality from './CarouselStaticFunctionality.svelte'
throws the above error and the build fails. (Although it works perfectly fine when you’re not wanting to hydrate on the client) Whereas:import CarouselStaticFunctionality from './CarouselStaticFunctionality.svelte'
works fine for hydrating on the client.