0.1.3 • Published 9 years ago

@timkendrick/skivvy-package-react-app v0.1.3

Weekly downloads
-
License
ISC
Repository
github
Last release
9 years ago

Skivvy package: @timkendrick/react-app

npm version Stability Build Status

ESLint/Mocha/ES6/JSX/Browserify/Stylus app tasks

Installation

skivvy install @timkendrick/react-app

Overview

This package allows you to perform ESLint/Mocha/ES6/JSX/Browserify/Stylus app tasks from within the Skivvy task runner.

Configuration settings:

NameTypeRequiredDefaultDescription
sourceobjectNoN/APaths to source files
source.scriptsstringNo"src/scripts"Path to JS source files
source.stylesstringNo"src/styles"Path to Stylus source files
source.templatesstringNo"src/templates"Path to HTML page templates folder
source.assetsstringNo"src/assets"Path to assets folder
testsstringNo"test"Path to test root
destinationstringNo"dist"Path to destination root
portnumberNo3000Port to use for preview server
debugbooleanNofalseWhether to run the tasks in dev mode

Included tasks

test

Lint source files and run unit tests

Usage:

skivvy run test

Configuration settings:

NameTypeRequiredDefaultDescription
scriptsstringNo"<%= package.source.scripts %>"Path to JS source files
testsstringNo"<%= package.tests %>"Path to test root
mochastringNo"<%= package.tests %>/**/*.spec.js"Path to Mocha specs

build

Run the test task, clean destination folder, copy assets and compile source files

If the package's debug configuration setting is true, this task will watch for changes.

Usage:

skivvy run build

Configuration settings:

NameTypeRequiredDefaultDescription
sourceobjectNoN/APaths to source files
source.scriptsstringNo"<%= package.source.scripts %>"Path to JS source files
source.jsstringNo"<%= package.source.scripts %>/index.js"Path to JS entry point
source.stylesstringNo"<%= package.source.styles %>"Path to Stylus source files
source.stylusstringNo"<%= package.source.styles %>/index.styl"Path to Stylus entry point
source.assetsstringNo"<%= package.source.assets %>"Path to assets folder
source.indexstringNo"<%= package.source.templates %>/index.html"Path to HTML page template
destination.rootstringNo"<%= package.destination %>"Path to destination root folder
destination.indexstringNo"<%= package.destination %>/index.html"Path to destination HTML file
destination.jsstringNo"<%= package.destination %>/js/app.js"Path to destination JS file
destination.cssstringNo"<%= package.destination %>/css/app.css"Path to destination CSS file

serve

Run the build task and launch a preview server

Usage:

skivvy run serve

Configuration settings:

NameTypeRequiredDefaultDescription
rootstringNo"<%= package.destination %>"Path to destination root
portnumberNo"<%= package.port %>"Port to use for preview server
watchbooleanNo"<%= package.debug %>"Whether to reload on file changes

create-app

Create a new app component

Usage:

skivvy run create-app

Configuration settings:

NameTypeRequiredDefaultDescription
namestringNoN/AApp component name
destinationstringNo"<%= package.source.scripts %>/apps"Path to app components folder

create-view

Create a new view component

Usage:

skivvy run create-view

Configuration settings:

NameTypeRequiredDefaultDescription
namestringNoN/AView component name
destinationstringNo"<%= package.source.scripts %>/views"Path to view components folder

create-component

Create a new component

Usage:

skivvy run create-component

Configuration settings:

NameTypeRequiredDefaultDescription
namestringNoN/AComponent name
destinationstringNo"<%= package.source.scripts %>/components"Components folder