Terra Toolkit
Terra Toolkit is a Lerna repository for common development packages necessary for developing Terra projects.
Notice
The code for the terra-toolkit npm dependency has been moved to terra-toolkit-boneyard.
Package Status
Versioning
Terra-toolkit packages are considered to be stable and will follow SemVer for versioning.
- MAJOR versions represent breaking changes
- MINOR versions represent added functionality in a backwards-compatible manner
- PATCH versions represent backwards-compatible bug fixes
Consult the component CHANGELOGs, related issues, and PRs for more information.
Contributing
Please read through our contributing guidelines. Included are directions for issue reporting and pull requests.
Local Development
- Install docker https://www.docker.com/ to run browser tests.
- Install dependencies and run tests.
npm install
npm run test
Local Development using Docker (Dev Containers)
- Install Rancher or Docker.
- Rancher is free and open-source and is highly recommended whereas Docker may require a license for use.
- Install Microsoft VS Code.
- Install the Dev Container extension.
- Navigate to View -> Extension -> Search for and install Dev Containers (or "ms-vscode-remote.remote-containers")
- More information on Dev Containers
- Build the dev container:
- (Option 1) - Opening local workspace in dev container
- Clone the repository (or fork) locally and open the project in Visual Studio Code
- Navigate to View -> Command Palette and run Dev Containers: Open Workspace in Container
- (Option 2) - Recommended for Windows for hot-reloading to work during development and improved performance: Creating the dev container using dev volumes (for more information and guidance, see the Official Guide)
- If you have git setup and have global config file ~/.gitconfig locally, these settings should automatically be transferred to the dev container
- Navigate to View -> Command Palette and run Dev Containers: Clone Repository in Container Volume
- Paste the GitHub URL of this repository (or fork)
- VS Code will now reload the workspace and create/start the dev container and volume
- Please note: changes made using this option will only update files in the Docker volume. It is recommended to commit changes often in case the volume is deleted or dev container gets removed.
- You're now running in a dev container. Use the terminal of the dev container in Visual Studio Code to issue any npm or bash commands.
- Before running any WDIO tests, make sure to perform the following steps:
- To terminate a dev container:
- Use command line or Rancher/Docker Desktop OR
- Using Visual Studio Code
- Select the Remote Explorer icon in the Activity Bar or View -> Command Palette and run Remote Explorer: Focus on Containers View
- Locate the terra-toolkit_devcontainer or currently running dev container under "Dev Containers"
- Right click and select Stop Container and close the workspace
- You can also select Rebuild Container to restart the dev container
- To reopen a dev container:
- Existing local workspace (for Option 1)
- Open the project in Visual Studio Code
- Ensure the workspace contains the .devcontainer folder
- Navigate to View -> Command Palette and run Dev Containers: Open Workspace in Container
- Isolated dev container volume (for Option 2)
- Open Visual Studio Code
- Use the Remote Explorer icon in the Activity Bar or View -> Command Palette and run Remote Explorer: Focus on Containers View to view containers
- Locate the terra-toolkit_devcontainer under "Dev Containers"
- Hover over the dev container and click the Folder icon labelled Open Folder in Container or by right clicking and selecting Open Folder in Container
LICENSE
Copyright 2017 - present Cerner Innovation, Inc.
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.