@modsy/react-modsy-scripts
Configuration and scripts for Create React App.
Last updated 3 years ago by modsy .
BSD-3-Clause · Repository · Bugs · Original npm · Tarball · package.json
$ cnpm install @modsy/react-modsy-scripts 
SYNC missed versions from official npm registry.

react-scripts-ts-sass

This package is a fork from the vanilla react-scripts, in order to add custom support for Typescript and Sass.

This package includes scripts and configuration used by Create React App. Please refer to its documentation:

Support

  • [x] JS/ES6
  • [x] Typescript
  • [x] SASS
  • [x] Multiple Entry Points
  • [x] Automatic Browser Open disabled by default (CRA_OPEN_BROWSER=true to reenable)

JS/ES6 support has been kept in, so you can use JS/ES6 and Typescript in the same project if you need to.

Usage

By default, you should have a src/index.js or src/index.tsx entry point. This will create the primary app bundle.

Multiple Entry Points

Your application src directory should contain a index.js or index.tsx file.

Alternatively, if you are building a an application with multiple entry points, you can create additional entry points by appending index before the filename extension.

When a filename following the convention of src/*.index.(ts|tsx|js|jsx) is detected, a new entry point will be added to the webpack entrypoint config.

A new html file will also be automatically generated, and default to using the public/index.html template if you did not create a custom template inside public.

To use a custom index.html, you can create a new html file with the matching entry point key.

Example:

src/index.tsx -> public/index.html
src/alt.index.tsx -> public/alt.html

The filetypes support for entry points are:

  • tsx
  • ts
  • js
  • jsx

NOTE: Periods after the first one will be ignored. If you want to generate additional index files for bundles named like one.two.three.index.js, it will be ignored and treated like one.index.js and generate a one.html. Use dashes or underscores as an alternative (ie. one-two-three.index.js -> one-two-three.html).

References

Current Tags

  • 0.3.4                                ...           latest (3 years ago)

21 Versions

  • 0.3.4                                ...           3 years ago
  • 0.3.3                                ...           3 years ago
  • 0.3.2                                ...           3 years ago
  • 0.3.1                                ...           3 years ago
  • 0.3.0                                ...           3 years ago
  • 0.2.6                                ...           3 years ago
  • 0.2.5                                ...           3 years ago
  • 0.2.4                                ...           3 years ago
  • 0.2.3                                ...           3 years ago
  • 0.2.2                                ...           3 years ago
  • 0.2.1                                ...           3 years ago
  • 0.2.0                                ...           3 years ago
  • 0.1.0                                ...           3 years ago
  • 0.0.9                                ...           3 years ago
  • 0.0.8                                ...           3 years ago
  • 0.0.7                                ...           3 years ago
  • 0.0.6                                ...           3 years ago
  • 0.0.5                                ...           3 years ago
  • 0.0.4                                ...           3 years ago
  • 0.0.3                                ...           3 years ago
  • 0.0.2                                ...           3 years ago
Maintainers (2)
Downloads
Today 0
This Week 0
This Month 1
Last Day 0
Last Week 0
Last Month 2
Dev Dependencies (2)
Dependents (0)
None

Copyright 2014 - 2016 © taobao.org |