Skip to content

Commit

Permalink
fix(create-vite): project name with only numbers as an argument (vite…
Browse files Browse the repository at this point in the history
  • Loading branch information
task4233 authored and aleclarson committed Nov 8, 2021
1 parent 304cebd commit 02c99b6
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion packages/create-vite/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,9 @@
// @ts-check
const fs = require('fs')
const path = require('path')
const argv = require('minimist')(process.argv.slice(2))
// Avoids autoconversion to number of the project name by defining that the args
// non associated with an option ( _ ) needs to be parsed as a string. See #4606
const argv = require('minimist')(process.argv.slice(2), { string: ['_'] })
// eslint-disable-next-line node/no-restricted-require
const prompts = require('prompts')
const {
Expand Down

0 comments on commit 02c99b6

Please sign in to comment.