setup-routify-ts

1.0.0-pre.4 • Public • Published

NPM Version Github License

setup-routify-ts (Unofficial)

Use Typescript in Routify Starter Template.

Usage

setup-routify-ts supports creating projects from scratch or converting existing projects. please select according to your needs.

Method 1: Create new Routify Starter Template

Command

npx setup-routify-ts init <project-name> [routify-init-args]

Arguments

  • project-name: Your project name (will be used as the folder name).
  • routify-init-args: Some arguments will be passed to npx @sveltech/routify init command. See Routify Get Started.

Example

npx setup-routify-ts init my-routify-app

Method 2: Convert existing projects to Typescript

Command

npx setup-routify-ts convert [project-directory]

Arguments

  • project-directory: Path to your project folder. Default: .(Current folder).

Example

npx setup-routify-ts convert /home/me/my-routify-app

What we do

  • Create new tsconfig.json file in root folder.
  • Add svelte-check script & some devDependencies to package.json.
  • Rename src/main.js to src/main.ts.
  • Add lang property to script element in src/App.svelte.
  • Add some plugins & configurations to scripts/base.config.js.
  • Create new extensions.json file in .vscode directory.

Note

Routify repository:

Routify is a work in progress. Since v1.5 we have a stable release. But this is a relatively young project. You can expect it to evolve.

Since Routify is in the progress, a lot of changes are likely to occur. If you find an error or something that is not updated, please inform us in the Issues section or fix it yourself by creating a new Pull Request.


Tested with @sveltech/routify@v1.9.9

Package Sidebar

Install

npm i setup-routify-ts

Weekly Downloads

0

Version

1.0.0-pre.4

License

WTFPL

Unpacked Size

8.86 kB

Total Files

9

Last publish

Collaborators

  • laodemalfatih