loopbackio / loopbackio/loopback-next

[CLI] `lb4` does not create app with uppercase letters

Open
#1,663 10 comments 0 reactions 1 assignee View on GitHub

@javiersantossanchez is already working on this.

Since Oct 12, 2020.

CLI developer-experience feature good first issue
Dominant language
TypeScript
Stars
5.1k
Forks
1.1k
Avg merge
2d 21h
Merged PRs (30d)
27

Description

## Description / Steps to reproduce / Feature proposal

```sh
$ lb4 myLB4app
> Generation is aborted: Invalid npm package name: myLB4app
```

This is likely due to the `package.json`'s `name` format restriction. We should use the user-submitted name for everything (directory name etc.), except for the `name` property in `package.json`; for that, CLI should do the hyphenation and lowercasing for the user.

Thoughts?

## Current Behavior

`lb4` refuses to create an app if it contains uppercase letters.

## Expected Behavior

Should allow creation of apps with uppercase and lowercase letters.

_See [Reporting Issues](http://loopback.io/doc/en/contrib/Reporting-issues.html) for more tips on writing good issues_

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.