Research
Security News
Quasar RAT Disguised as an npm Package for Detecting Vulnerabilities in Ethereum Smart Contracts
Socket researchers uncover a malicious npm package posing as a tool for detecting vulnerabilities in Etherium smart contracts.
cra-template-red-quick
Advanced tools
[![npm version](https://badge.fury.io/js/cra-template-typescript-redux.svg)](https://badge.fury.io/js/cra-template-typescript-redux) [![Action status](https://github.com/alexandr-g/cra-template-typescript-redux/workflows/CI/badge.svg?branch=master)](http
An opinionated quick start Create React App (CRA) template with configured Redux, TypeScript, React Router, Enzyme and custom ESlint configuration.
Original Create React App README available here
npx create-react-app your-project-name --template typescript-redux
Or
yarn create react-app your-project-name --template typescript-redux
npx
command installs the most recent stable version of CRA from npm.
--template
parameter points to this template, note that cra-template-
prefix is omitted.
You know the pain. You start a new project from scratch and need to configure it again and again. It needs routing, ok you setup Router, then you need Redux - ok, oh 😩 Redux boilerplate is taking so much time to type. Wait... what if you could have all the tools you want just from the beginning? I want to focus on building amazing projects and not spending hours configuring. That's why I've created this template. It's here for you to use.
In the project directory, you can run:
yarn start
- runs the app in the development mode. Open http://localhost:3000 to view it in the browser.
yarn test
- launches the test runner in the interactive watch mode.
yarn build
- builds the app for production to the build
folder.
yarn eject
- exposes content of react-script
package
yarn lint
- lints project files according to eslint rules, see below. Typical use case: continuous integration environments, Travis, CircleCI, etc.
yarn fix
- same as yarn lint
, but also fixes errors, when possible. Typical use case: local development environment, git hooks.
Due to CRA template limitations (we can change only scripts
and dependencies
inside generated package.json
) all configuration is done by adding config files where possible. Also no devDependencies
for now, sorry.
The template provides basic Redux configuration with feature based folder structure. You can use Redux devtools browser extension. Sample feature included in src/features
folder, note technology agnostic features
folder name. Based on Redux maintainers recommendation.
Testing is done with Enzyme.
I added prettier
to force consistent formatting. Don't like trailing semicolons? Feel free to tweak prettier rules inside .prettierrc
file to match your code style.
Just for the styling purpose of the example app, I used Materialize. The template is shipped with the Materialize by default. I want to make sure that this template is style agnostic so you can plugin any CSS-in-JS or whatever library/framework you want to use for styles on your own.
In order to remove Materialize MaterializeCSS navigate to the public
folder, open index.html
and remove following CDN link in the <head>
lines 18-22:
<!--Import materialize.css-->
<link
rel="stylesheet"
href="https://cdnjs.cloudflare.com/ajax/libs/materialize/1.0.0/css/materialize.min.css"
/>
Remove or adjust all the classNames
related to the Materialize and feel free to use your own styling.
The template extends CRA ESLint rules with a custom set, tailored for the reasonable and clean development process.
Eslint rules are commented for your convenience feel free to tweak or remove them inside .eslintrc
. No judgment.
To test the output of your template locally run
npx create-react-app my-app --template file:/\path\to\file
I created a step by step guide on how to create your own templates.
A light weight Create React App template with Recoil for state management
I hope this template will be helpful for you and you will love using it 🖤
FAQs
[![npm version](https://badge.fury.io/js/cra-template-typescript-redux.svg)](https://badge.fury.io/js/cra-template-typescript-redux) [![Action status](https://github.com/alexandr-g/cra-template-typescript-redux/workflows/CI/badge.svg?branch=master)](http
The npm package cra-template-red-quick receives a total of 0 weekly downloads. As such, cra-template-red-quick popularity was classified as not popular.
We found that cra-template-red-quick demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Research
Security News
Socket researchers uncover a malicious npm package posing as a tool for detecting vulnerabilities in Etherium smart contracts.
Security News
Research
A supply chain attack on Rspack's npm packages injected cryptomining malware, potentially impacting thousands of developers.
Research
Security News
Socket researchers discovered a malware campaign on npm delivering the Skuld infostealer via typosquatted packages, exposing sensitive data.