question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Build error with v1.2.1: TypeError [ERR_INVALID_ARG_TYPE]: The "id" argument must be of type string. Received undefined

See original GitHub issue

Hello!

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:closed
  • Created 3 years ago
  • Comments:6 (2 by maintainers)

github_iconTop GitHub Comments

1reaction
s-kriscommented, Feb 27, 2021

You need restart the dev

0reactions
kookydevcommented, Sep 29, 2021

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.

Read more comments on GitHub >

github_iconTop 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 >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found