UNPKG

@decaf-ts/styles

Version:
112 lines (70 loc) 5.67 kB
![Banner](./workdocs/assets/decaf-logo.svg) ## Typescript Template This repository is meant to provide an enterprise template for any standard Typescript project ![Licence](https://img.shields.io/github/license/decaf-ts/ts-workspace.svg?style=plastic) ![GitHub language count](https://img.shields.io/github/languages/count/decaf-ts/ts-workspace?style=plastic) ![GitHub top language](https://img.shields.io/github/languages/top/decaf-ts/ts-workspace?style=plastic) [![Build & Test](https://github.com/decaf-ts/ts-workspace/actions/workflows/nodejs-build-prod.yaml/badge.svg)](https://github.com/decaf-ts/ts-workspace/actions/workflows/nodejs-build-prod.yaml) [![CodeQL](https://github.com/decaf-ts/ts-workspace/actions/workflows/codeql-analysis.yml/badge.svg)](https://github.com/decaf-ts/ts-workspace/actions/workflows/codeql-analysis.yml)[![Snyk Analysis](https://github.com/decaf-ts/ts-workspace/actions/workflows/snyk-analysis.yaml/badge.svg)](https://github.com/decaf-ts/ts-workspace/actions/workflows/snyk-analysis.yaml) [![Pages builder](https://github.com/decaf-ts/ts-workspace/actions/workflows/pages.yaml/badge.svg)](https://github.com/decaf-ts/ts-workspace/actions/workflows/pages.yaml) [![.github/workflows/release-on-tag.yaml](https://github.com/decaf-ts/ts-workspace/actions/workflows/release-on-tag.yaml/badge.svg?event=release)](https://github.com/decaf-ts/ts-workspace/actions/workflows/release-on-tag.yaml) ![Open Issues](https://img.shields.io/github/issues/decaf-ts/ts-workspace.svg) ![Closed Issues](https://img.shields.io/github/issues-closed/decaf-ts/ts-workspace.svg) ![Pull Requests](https://img.shields.io/github/issues-pr-closed/decaf-ts/ts-workspace.svg) ![Maintained](https://img.shields.io/badge/Maintained%3F-yes-green.svg) ![Forks](https://img.shields.io/github/forks/decaf-ts/ts-workspace.svg) ![Stars](https://img.shields.io/github/stars/decaf-ts/ts-workspace.svg) ![Watchers](https://img.shields.io/github/watchers/decaf-ts/ts-workspace.svg) ![Node Version](https://img.shields.io/badge/dynamic/json.svg?url=https%3A%2F%2Fraw.githubusercontent.com%2Fbadges%2Fshields%2Fmaster%2Fpackage.json&label=Node&query=$.engines.node&colorB=blue) ![NPM Version](https://img.shields.io/badge/dynamic/json.svg?url=https%3A%2F%2Fraw.githubusercontent.com%2Fbadges%2Fshields%2Fmaster%2Fpackage.json&label=NPM&query=$.engines.npm&colorB=purple) Documentation available [here](https://decaf-ts.github.io/ts-workspace/) ### Description No one needs the hassle of setting up new repos every time. Now you can create new repositories from this template and enjoy having everything set up for you. ### How to Use - [Initial Setup](./tutorials/For%20Developers.md#_initial-setup_) - [Installation](./tutorials/For%20Developers.md#installation) - [Scripts](./tutorials/For%20Developers.md#scripts) - [Linting](./tutorials/For%20Developers.md#testing) - [CI/CD](./tutorials/For%20Developers.md#continuous-integrationdeployment) - [Publishing](./tutorials/For%20Developers.md#publishing) - [Structure](./tutorials/For%20Developers.md#repository-structure) - [IDE Integrations](./tutorials/For%20Developers.md#ide-integrations) - [VSCode(ium)](./tutorials/For%20Developers.md#visual-studio-code-vscode) - [WebStorm](./tutorials/For%20Developers.md#webstorm) - [Considerations](./tutorials/For%20Developers.md#considerations) ## Coding Principles - group similar functionality in folders (analog to namespaces but without any namespace declaration) - one class per file; - one interface per file (unless interface is just used as a type); - group types as other interfaces in a types.ts file per folder; - group constants or enums in a constants.ts file per folder; - group decorators in a decorators.ts file per folder; - always import from the specific file, never from a folder or index file (exceptions for dependencies on other packages); - prefer the usage of established design patters where applicable: - Singleton (can be an anti-pattern. use with care); - factory; - observer; - strategy; - builder; - etc; ### Related [![Readme Card](https://github-readme-stats.vercel.app/api/pin/?username=decaf-ts&repo=ts-workspace)](https://github.com/decaf-ts/ts-workspace) ### Social [![LinkedIn](https://img.shields.io/badge/LinkedIn-0077B5?style=for-the-badge&logo=linkedin&logoColor=white)](https://www.linkedin.com/in/decaf-ts/) #### Languages ![TypeScript](https://img.shields.io/badge/TypeScript-007ACC?style=for-the-badge&logo=typescript&logoColor=white) ![JavaScript](https://img.shields.io/badge/JavaScript-F7DF1E?style=for-the-badge&logo=javascript&logoColor=black) ![NodeJS](https://img.shields.io/badge/Node.js-43853D?style=for-the-badge&logo=node.js&logoColor=white) ![ShellScript](https://img.shields.io/badge/Shell_Script-121011?style=for-the-badge&logo=gnu-bash&logoColor=white) ## Getting help If you have bug reports, questions or suggestions please [create a new issue](https://github.com/decaf-ts/ts-workspace/issues/new/choose). ## Contributing I am grateful for any contributions made to this project. Please read [this](./workdocs/98-Contributing.md) to get started. ## Supporting The first and easiest way you can support it is by [Contributing](./workdocs/98-Contributing.md). Even just finding a typo in the documentation is important. Financial support is always welcome and helps keep both me and the project alive and healthy. So if you can, if this project in any way. either by learning something or simply by helping you save precious time, please consider donating. ## License This project is released under the [MIT License](./LICENSE.md). By developers, for developers...