This repository has been archived by the owner on Jul 8, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 8
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
55 changed files
with
600 additions
and
192 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
The MIT License (MIT) | ||
|
||
Copyright (c) <%= appYear %> LabShare | ||
|
||
Permission is hereby granted, free of charge, to any person obtaining a copy | ||
of this software and associated documentation files (the "Software"), to deal | ||
in the Software without restriction, including without limitation the rights | ||
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell | ||
copies of the Software, and to permit persons to whom the Software is | ||
furnished to do so, subject to the following conditions: | ||
|
||
The above copyright notice and this permission notice shall be included in all | ||
copies or substantial portions of the Software. | ||
|
||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR | ||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, | ||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE | ||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER | ||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, | ||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE | ||
SOFTWARE. | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,114 @@ | ||
# <%= appTitle %> | ||
|
||
## Overview | ||
|
||
This is a template project with all the LabShare's features, such as Authentication, Usage, Configuration and more. | ||
|
||
## Tutorial | ||
|
||
- Install all the packages: `npm i` | ||
|
||
- To run this project in development mode, you need to use the command line: `lsc start site` | ||
|
||
* To run this project as a desktop app, you need to use the command line: `lsc start app` | ||
|
||
* To build this project as a production bundle, you need to use the command line: `lsc build site` | ||
|
||
* For more information, go to @labshare/shell-ui. | ||
|
||
## Contents | ||
|
||
- **UI** - Main UI folder. | ||
- **App** - Main App Folder. | ||
- **Core**: Main Functionality module, all the current's project logic should go here. | ||
- **Shell**: Shell Module, all the default routes, and services initialization goes here. | ||
- **Theme**: UI Module, all the settings for the main ui module goes here. | ||
- **app-routing**: Main Routing module. | ||
- **App Module**: Main module. | ||
|
||
## Application Configuration | ||
|
||
For adding configuration to the application, you have two options: | ||
|
||
- Create a config.json file at the root folder (legacy version). | ||
- Change the default values at default.json; With this approach, you can take advantage of | ||
[configjs](https://www.npmjs.com/package/config) and have several features like: Support for multiple configurations: | ||
Add a file with the name of the configuration you will like to use: `staging.json` For loading lsc with the new | ||
configuration, type: | ||
|
||
```sh | ||
lsc start site --config=staging | ||
``` | ||
|
||
Adding the `--config={name of the environment}`, allows you to have multiple configurations. | ||
|
||
If you desire to use environment variables, you can create a .env file and change the configuration to either | ||
`default.ts` or `default.js` and export the process.env.VARIABLE_NAME: | ||
|
||
```js | ||
//default.js | ||
module.exports ={ | ||
"configuration_value" : process.env.VALUE; | ||
} | ||
``` | ||
|
||
## Environment Configuration | ||
|
||
If you want to change your environment configuration, you will need to the .labsharerc file, there are the options: | ||
|
||
```json | ||
{ | ||
"tsConfig": "tsconfig.json", // path to you tsconfig file | ||
"build": { | ||
// build options | ||
"main": "ui/main", // main entry point | ||
"polyfills": "ui/polyfills", // polyfills path | ||
"assets": "ui/assets", // assets folder | ||
"app": "ui/app", // app path | ||
"index": "ui/index.ejs" // index file | ||
}, | ||
"serve": { | ||
// development server | ||
"open": true, // open a new browser window | ||
"hot": true, // hot reload | ||
"port": 8080, // development port | ||
"historyApiFallback": true, // history api fallback | ||
"stats": "minimal" // stats | ||
// you can add more settings, check webpack dev server options for more // information | ||
} | ||
} | ||
``` | ||
|
||
## NPM Scripts | ||
|
||
- **start**: Starts the site in dev mode | ||
- **test:watch**: Tests and development with watch | ||
- **test**: Run tests | ||
- **coverage**: Run coverage | ||
- **prettier**: Run prettier for fixing the code structure | ||
- **lint**: Run lint for checking the code | ||
- **lint:fix**: Fixes all lint and prettier issues | ||
- **tslint**: Run tslint for checking ts code | ||
- **tslint:fix**: Fixes any tslint issues | ||
- **prettier:check**: Check the code with Prettier | ||
- **prettier:cli**: Run the prettier cli | ||
- **prettier:fix**:Fixes any prettier issue | ||
- **build**: Builds the site | ||
- **commitmsg**: Checks the commit messages | ||
- **semantic-release**: Runs the semantic release | ||
|
||
## Docs | ||
|
||
Section for the project's documentation. | ||
|
||
## TravisCI | ||
|
||
The [travisCI](https://travis-ci.com/) file configuration. | ||
|
||
## Codecov | ||
|
||
[Codecov](https://codecov.io) configuration File. | ||
|
||
## License | ||
|
||
MIT |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
TEST="test value with Rafa" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,17 @@ | ||
{ | ||
"tsConfig" : "tsconfig.json", | ||
"build": { | ||
"main": "ui/main", | ||
"polyfills": "ui/polyfills", | ||
"assets": "ui/assets", | ||
"app": "ui/app", | ||
"index": "ui/index.ejs" | ||
}, | ||
"electron":{ | ||
"debug":false | ||
"serve":{ | ||
"open": true, | ||
"hot": true, | ||
"port": 8080, | ||
"historyApiFallback": true, | ||
"stats": "minimal" | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -4,4 +4,5 @@ | |
/images | ||
*.json | ||
CHANGELOG.md | ||
*.yml | ||
*.yml | ||
index.js |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,4 @@ | ||
{ | ||
"test-config":"Hello from config" | ||
|
||
} |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
# Tests | ||
|
||
Your project's tests can go here. |
Oops, something went wrong.