Skip to content

unknown-options-as-args doesn't work properly when a property has a number at the end. #231

@alan-agius4

Description

@alan-agius4

unknown-options-as-args doesn't work properly when a property has a number at the end.

require('yargs-parser')(['--str', '--num1'], {
    alias:{ 'num': ['n'] },
    configuration: {
      'unknown-options-as-args': true,
    }
});

Actual output

Object {_: ["--str"], num1: true}

Expected Output

Object {_: ["--str", "--num1"]}

yargs-parser version: 16.1.0

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions