3

I am using nuxt.js and encountered this error:

TypeError [ERR_INVALID_ARG_TYPE]: The 'request' argument must be string.

What does this error mean? I tried npm install. I think it's node js problem.

Following is my config file:

const pkg = require('./package')


module.exports = {
  mode: 'universal',

  /*
  ** Headers of the page
  */
  head: {
    title: pkg.name,
    meta: [
      { charset: 'utf-8' },
      { name: 'viewport', content: 'width=device-width, initial-scale=1' },
      { hid: 'description', name: 'description', content: pkg.description }
    ],
    link: [
      { rel: 'icon', type: 'image/x-icon', href: '/favicon.ico' },
      { rel: 'stylesheet', type: 'text/css', href: 'https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0/css/bootstrap.min.css'},
      { rel: 'stylesheet', href: 'https://fonts.googleapis.com/css?family=Open+Sans|Source+Sans+Pro'}
]
    
  }
1
  • 2
    its not enough info. Something in your code cause it.
    – Aldarund
    Commented May 12, 2019 at 10:34

1 Answer 1

1

Looks like the package-lock.json was the issue when I got that error. I've removed it and reinstalled node modules. It works fine ever after. You might want to check if that would work in your situation.

1
  • Removing package-lock.json is inadvisable for several reasons. Without further explanation this answer is problematic.
    – isherwood
    Commented Jun 10 at 16:43

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.