carbon-components-svelte/docs
2020-09-04 16:35:49 -07:00
..
cypress docs: add component grid 2020-07-24 17:19:19 -07:00
includes docs: use sapper/cypress for e2e testing 2020-07-19 11:41:15 -07:00
scripts docs: build carbon themes using sass 2020-07-23 19:58:54 -07:00
src chore(prettier): use svelteStrictMode 2020-09-04 16:35:49 -07:00
static [ImgBot] Optimize images 2020-07-19 18:56:18 +00:00
.cfignore docs: use sapper/cypress for e2e testing 2020-07-19 11:41:15 -07:00
.gitignore docs: add component grid 2020-07-24 17:19:19 -07:00
cypress.json docs: display button variants 2020-07-23 19:38:09 -07:00
manifest.yml docs: use sapper/cypress for e2e testing 2020-07-19 11:41:15 -07:00
package.json docs: extract TileCard component 2020-08-08 15:49:16 -07:00
README.md docs: build carbon themes using sass 2020-07-23 19:58:54 -07:00
Staticfile docs: use sapper/cypress for e2e testing 2020-07-19 11:41:15 -07:00
webpack.config.js docs: prefetch links 2020-07-24 21:00:28 -07:00
yarn.lock docs: extract TileCard component 2020-08-08 15:49:16 -07:00

docs

This application was scaffolded using the default webpack Sapper template.

Purpose

  • Write integration/end-to-end tests using Cypress
  • Serve as an alternative component development environment to Storybook
  • Build components in a Server-side Rendering (SSR) environment

Getting Started

carbon-components-svelte must be linked in order to reflect live updates during component development.

In the root folder of this project, run the following:

# carbon-components-svelte/
yarn link

Then, in this folder, link the package and install the dependencies:

cd docs

# carbon-components-svelte/docs/
yarn link "carbon-components-svelte"
yarn install

Before starting development, you will need to build the Carbon-themed CSS StyleSheet once.

node scripts/carbon-theme

A file containing the four Carbon themes will be outputted to static/style.css. Do not check this file into source control.

Available Scripts

yarn dev

Runs the Sapper app in development mode.

yarn build

Builds the app for production (static export only).

yarn test

Runs Cypress integration tests in a headless browser (i.e. CLI only).

yarn:test:tdd

Runs Cypress tests in the Cypress GUI. This is helpful when authoring new tests.

Deploying to IBM Cloud

Deploy to IBM Cloud using the Staticfile buildpack.

Log in

Log in using the IBM Cloud CLI:

ibmcloud login

# or if using Single-Sign On (SSO):
ibmcloud login --sso

Deploy

Build and deploy the app:

yarn build
ibmcloud target --cf
ibmcloud cf push