UNPKG

@bootcamp-project/svelte-config

Version:

Ready-to-use Svelte Configuration with TypeScript, Linting and Unit-Testing by default

196 lines (152 loc) 10.1 kB
<!-- MIT License Copyright (c) 2021 Bootcamp-Project contributors <contributors@bootcamp-project.com> Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. --> <a href="https://bootcamp-project.com/" target="_blank"><img src="https://bootcamp-project.com/tbcp.svg" align="right" height="200" /></a> # Ready-to-use Svelte Configuration ## with TypeScript, Linting and Unit-Testing by default <img src="https://img.shields.io/npm/v/@bootcamp-project/svelte-config?style=for-the-badge"> <img src="https://img.shields.io/npm/types/@bootcamp-project/svelte-config?style=for-the-badge"> <img src="https://img.shields.io/librariesio/release/npm/@bootcamp-project/svelte-config?style=for-the-badge"> <img src="https://img.shields.io/gitlab/pipeline-status/the-bootcamp-project/configurations/svelte?branch=main&style=for-the-badge"> <img src="https://img.shields.io/npm/dm/@bootcamp-project/svelte-config?style=for-the-badge"> <img src="https://img.shields.io/badge/License-MIT-lightgrey?style=for-the-badge" /> <img src="https://img.shields.io/badge/Bootcamp-Project-blue?style=for-the-badge" /> ## 🦄 About 🦄 **Minimum Viable Product**: *What is what we want?* > *The creation and deployment of a centralized sharable configuration, with the most well-known best practice approaches.* - **What are the goals?** - [X] Automation of publishing, testing, linting and packaging with GitLab-CI - [X] Provide understandable documentation for the use of the configuration - [X] Test the return of the configuration with unit tests and the validation of the configuration structure with smoke tests. - [X] For the greatest possible compatibility we provide TypeScript definitions - [X] Use the unified [ESLint and Prettier configuration][RTFM_ESLintPrettier] for static analysis of the source code - [X] Create a best possible configuration for bundling svelte components at disposal ## 🚀 Getting Started 🚀 **Project Links** - [Homepage][Project_Homepage] - [Documentation][Project_Docs] - [Repository][Repo_URL] - [Issues][Repo_Issues] ### 💪 Installation 💪 ```bash yarn add @bootcamp-project/svelte-config ``` **or** ```bash npm install @bootcamp-project/svelte-config ``` ### 🤩 Usage 🤩 > See [@bootcamp-project/svelte-config preselections][Project_Config] #### Best practice Svelte Config Example ```js // svelte.config.js 'use strict'; const SvelteConfig = require('@bootcamp-project/svelte-config/svelte.config') module.exports = SvelteConfig ``` ## ⭐️ Features ⭐️ - TypeScript definitions (**@types**) included - [**Smoke** and **Unit-tested**][Repo_Tests] modules - Latest **Dependencies** preinstalled *Batteries included!* - Security-first production-ready [**configurations**][TBCP_Configurations] by default - Extensive [**documentation**][Project_Docs] ### 😎 Built With 😎 <table> <tr> <td><a href="https://svelte.dev/" target="_blank"><img src="https://cdr.bootcamp-project.com/logos/programming/svelte.svg" alt="Svelte" width="200"/></a></td> <td><a href="https://tailwindcss.com/" target="_blank"><img src="https://cdr.bootcamp-project.com/logos/programming/tailwindcss.svg" alt="Tailwind CSS" width="200"/></a></td> <td><a href="https://eslint.org/" target="_blank"><img src="https://cdr.bootcamp-project.com/logos/programming/eslint.svg" alt="eslint" width="200"/></a></td> <td><a href="https://typescriptlang.org/" target="_blank"><img src="https://cdr.bootcamp-project.com/logos/programming/typescript.svg" alt="TypeScript" width="200"/></a></td> <td><a href="https://bootcamp-project.com/" target="_blank"><img src="https://bootcamp-project.com/tbcp.svg" alt="tbcp" width="200"/></a></td> </tr> </table> ### 🏆 Acknowledgements 🏆 Thanks for these awesome resources that were used during the development of the **Bootcamp: Svelte Configuration**: - Library: [Svelte][URL_Svelte] - Library: [Tailwind CSS][URL_Tailwind] - How-to: [RTFM.page: Svelte][RTFM_Svelte] - How-to: [RTFM.page: Mocha + Chai][RTFM_MochaChai] - How-to: [RTFM.page: TypeScript][RTFM_TypeScript] - How-to: [TBCP-Framework: Modern Web Application][TBCP_FW_WebApp] ## 📑 Changelog 📑 See [CHANGELOG][Repo_Changelog] for more information. ## 📋 Roadmap 📋 See the [open issues][Repo_Issues] for a list of proposed features (and known issues). ## 🤝 Contribute 🤝 Contributions are what make the open source community such an amazing place to be learn, inspire, and create. Any contributions you make are **greatly appreciated**. Please read the [contribution guidelines][TBCP_Contribution] first. 0. [Give us a star][Repo_Stars], it's really important! 😅 1. Fork the Project: (`git clone https://gitlab.com/the-bootcamp-project/configurations/svelte.git`) 2. Create your Feature Branch (`git checkout -b feature/AmazingFeature`) 3. Commit your Changes (`git commit -m 'Add some AmazingFeature'`) 4. Push to the Branch (`git push origin feature/AmazingFeature`) 5. Open a Pull Request ## 📜 License 📜 See [LICENSE][Repo_License] for more information. ## 💌 Contact 💌 [Bootcamp contributors][TBCP_Homepage] - `contributors` @ `bootcamp-project` .com <!-- ---------------------------------------------------------------------------------------------------------------------------------- --> <!-- ---------------------------------------------------------------------------------------------------------------------------------- --> <!-- ---------------------------------------------------------------------------------------------------------------------------------- --> [Project_Homepage]: https://configurations.bootcamp-project.com/#/ui_frameworks/svelte [Project_Docs]: https://configurations.bootcamp-project.com/#/ui_frameworks/svelte [Project_Config]: https://configurations.bootcamp-project.com/#/ui_frameworks/svelte_config <!-- ---------------------------------------------------------------------------------------------------------------------------------- --> [Repo_URL]: https://gitlab.com/the-bootcamp-project/configurations/svelte [Repo_Issues]: https://gitlab.com/the-bootcamp-project/configurations/svelte/-/issues [Repo_Forks]: https://gitlab.com/the-bootcamp-project/configurations/svelte/-/forks [Repo_Stars]: https://gitlab.com/the-bootcamp-project/configurations/svelte/-/starrers [Repo_Tests]: https://gitlab.com/the-bootcamp-project/configurations/svelte/-/tree/main/tests [Repo_License]: https://gitlab.com/the-bootcamp-project/configurations/svelte/-/blob/main/LICENSE [Repo_Changelog]: https://gitlab.com/the-bootcamp-project/configurations/svelte/-/blob/main/CHANGELOG <!-- ---------------------------------------------------------------------------------------------------------------------------------- --> [TBCP_Homepage]: https://bootcamp-project.com [TBCP_Configurations]: https://configurations.bootcamp-project.com [TBCP_FW_WebApp]: https://frameworks.bootcamp-project.com/#/webapp/index [TBCP_FW_WebExt]: https://frameworks.bootcamp-project.com/#/browser_extension/index [TBCP_FW_Desktop]: https://frameworks.bootcamp-project.com/#/native_desktop/index [TBCP_FW_Mobile]: https://frameworks.bootcamp-project.com/#/native_mobile/index [TBCP_Contribution]: https://bootcamp-project.com/#code_of_conduct <!-- ---------------------------------------------------------------------------------------------------------------------------------- --> [RTFM_Webpack]: https://dev.rtfm.page/#/working_with/javascript/webpack [RTFM_MochaChai]: https://dev.rtfm.page/#/working_with/javascript/mocha_chai_sinon_karma [RTFM_TypeScript]: https://dev.rtfm.page/#/working_with/javascript/typescript [RTFM_Tailwind]: https://dev.rtfm.page/#/working_with/javascript/tailwindcss [RTFM_Svelte]: https://dev.rtfm.page/#/working_with/javascript/svelte [RTFM_Rollup]: https://dev.rtfm.page/#/working_with/javascript/rollup [RTFM_Postcss]: https://dev.rtfm.page/#/working_with/javascript/postcss [RTFM_Jest]: https://dev.rtfm.page/#/working_with/javascript/jest [RTFM_ESLintPrettier]: https://dev.rtfm.page/#/working_with/javascript/eslint_prettier <!-- ---------------------------------------------------------------------------------------------------------------------------------- --> [URL_Webpack]: https://webpack.js.org/ [URL_TypeScript]: https://www.typescriptlang.org/ [URL_PostCSS]: https://postcss.org/ [URL_Autoprefixer]: https://autoprefixer.github.io/ [URL_Svelte]: https://svelte.dev/ [URL_WebExt]: https://extensionworkshop.com/ [URL_Tailwind]: https://tailwindcss.com/ [URL_Rollup]: https://rollupjs.org [URL_Jest]: https://jestjs.io/ [URL_ESlint]: https://eslint.org/ [URL_Prettier]: https://prettier.io/ [URL_Electron]: https://www.electronjs.org/ [URL_Capacitor]: https://capacitorjs.com/ <!-- ---------------------------------------------------------------------------------------------------------------------------------- --> <!-- ---------------------------------------------------------------------------------------------------------------------------------- --> <!-- ---------------------------------------------------------------------------------------------------------------------------------- -->