Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Angular-Cli camelCase name

It seems that when I used angular cli to generate components,services etc.by this command and name of component

ng g component myApp

It generate component folder and other files such as

my-app.component.ts

instead myapp.component.ts

My question is,Is there any command to generate components,services etc. with camelCase name.

I research for it,but nothing works.

like image 815
sandeep Avatar asked May 25 '17 04:05

sandeep


People also ask

How to name a service in Angular?

Service names such as Credit are nouns and require a suffix and should be named with a suffix when it is not obvious if it is a service or something else.

What is camel case letters?

What is CamelCase? CamelCase is a way to separate the words in a phrase by making the first letter of each word capitalized and not using spaces. It is commonly used in web URLs, programming and computer naming conventions. It is named after camels because the capital letters resemble the humps on a camel's back.

What is kebab case example?

Kebab case is similar to snake case, but you use a hyphen (-) instead of an underscore (_) to separate the words. Here are some examples of kebab case: first-name and last-name .


1 Answers

Angular Style Guide explicitly says to use my-app.component.ts for file names.

  • dash-case (or "kebab-case"): descriptive part of file names, component selectors

Reference: https://angular.io/guide/glossary

like image 174
mruanova Avatar answered Oct 11 '22 16:10

mruanova