Rename client_custom to custom
This commit is contained in:
parent
462528ef03
commit
746b5a9bfc
4 changed files with 11 additions and 11 deletions
|
@ -155,9 +155,9 @@ Spee.ch also runs a sync tool, which decodes blocks from the `LBRY` blockchain a
|
||||||
* `client/scss/` contains the CSS for the project
|
* `client/scss/` contains the CSS for the project
|
||||||
*
|
*
|
||||||
|
|
||||||
* `client_custom` is a folder which can be used to override the default components in `client/`
|
* `config/custom` is a folder which can be used to override the default components in `client/`
|
||||||
* The folder structure mimics that of the `client/` folder
|
* The folder structure mimics that of the `client/` folder
|
||||||
* to customize spee.ch, place your own components and scss in the `client_custom/src/` and `client_custom/scss` folders.
|
* to customize spee.ch, place your own components and scss in the `config/custom/src/` and `config/custom/scss` folders.
|
||||||
|
|
||||||
* `server/` contains all of the server code
|
* `server/` contains all of the server code
|
||||||
* `index.js` is the entry point for the server. It creates the [express app](https://expressjs.com/), requires the routes, syncs the database, and starts the server listening on the `PORT` designated in the config files.
|
* `index.js` is the entry point for the server. It creates the [express app](https://expressjs.com/), requires the routes, syncs the database, and starts the server listening on the `PORT` designated in the config files.
|
||||||
|
|
|
@ -3,14 +3,14 @@
|
||||||
_note: this guide assumes you have done the []quickstart](https://github.com/lbryio/spee.ch/blob/readme-update/README.md) or [fullstart](https://github.com/lbryio/spee.ch/blob/readme-update/fullstart.md) guide and have a working spee.ch server_
|
_note: this guide assumes you have done the []quickstart](https://github.com/lbryio/spee.ch/blob/readme-update/README.md) or [fullstart](https://github.com/lbryio/spee.ch/blob/readme-update/fullstart.md) guide and have a working spee.ch server_
|
||||||
|
|
||||||
## Custom Components
|
## Custom Components
|
||||||
The components used by spee.ch are taken from the `client/` folder, but you can override those components by defining your own in the `client_custom/` folder.
|
The components used by spee.ch are taken from the `client/` folder, but you can override those components by defining your own in the `site/custom/` folder.
|
||||||
|
|
||||||
### Add a new custom Logo component.
|
### Add a new custom Logo component.
|
||||||
|
|
||||||
To create your own custom component to override the defaults, create a folder and an `index.jsx` file for the component in the `client_custom/src/components/` folder.
|
To create your own custom component to override the defaults, create a folder and an `index.jsx` file for the component in the `site/custom/src/components/` folder.
|
||||||
|
|
||||||
```
|
```
|
||||||
$ cd client_custom/src/components/
|
$ cd site/custom/src/components/
|
||||||
$ mkdir Logo
|
$ mkdir Logo
|
||||||
$ cd Logo
|
$ cd Logo
|
||||||
$ touch index.jsx
|
$ touch index.jsx
|
||||||
|
|
|
@ -22,14 +22,14 @@
|
||||||
"test": "mocha --recursive",
|
"test": "mocha --recursive",
|
||||||
"test:no-lbc": "npm test -- --grep @usesLbc --invert",
|
"test:no-lbc": "npm test -- --grep @usesLbc --invert",
|
||||||
"test:server": "mocha --recursive './server/**/*.test.js'",
|
"test:server": "mocha --recursive './server/**/*.test.js'",
|
||||||
"transpile": "builder concurrent transpile:server transpile:client transpile:client_custom",
|
"transpile": "builder concurrent transpile:server transpile:client transpile:custom",
|
||||||
"transpile:dev": "builder concurrent transpile:server:dev transpile:client:dev transpile:client_custom:dev",
|
"transpile:dev": "builder concurrent transpile:server:dev transpile:client:dev transpile:custom:dev",
|
||||||
"transpile:server": "babel server/render/src -d server/render/build",
|
"transpile:server": "babel server/render/src -d server/render/build",
|
||||||
"transpile:server:dev": "babel server/render/src -w -d server/render/build",
|
"transpile:server:dev": "babel server/render/src -w -d server/render/build",
|
||||||
"transpile:client": "babel client/src -d client/build",
|
"transpile:client": "babel client/src -d client/build",
|
||||||
"transpile:client:dev": "babel client/src -w -d client/build",
|
"transpile:client:dev": "babel client/src -w -d client/build",
|
||||||
"transpile:client_custom": "babel site/client_custom/src -d site/client_custom/build",
|
"transpile:custom": "babel site/custom/src -d site/custom/build",
|
||||||
"transpile:client_custom:dev": "babel site/client_custom/src -w -d site/client_custom/build"
|
"transpile:custom:dev": "babel site/custom/src -w -d site/custom/build"
|
||||||
},
|
},
|
||||||
"repository": {
|
"repository": {
|
||||||
"type": "git",
|
"type": "git",
|
||||||
|
|
|
@ -1,8 +1,8 @@
|
||||||
const { statSync, existsSync, readdirSync } = require('fs');
|
const { statSync, existsSync, readdirSync } = require('fs');
|
||||||
const { join, resolve } = require('path');
|
const { join, resolve } = require('path');
|
||||||
const DEFAULT_ROOT = 'client/build';
|
const DEFAULT_ROOT = 'client/build';
|
||||||
const CUSTOM_ROOT = 'site/client_custom/build';
|
const CUSTOM_ROOT = 'site/custom/build';
|
||||||
const CUSTOM_SCSS_ROOT = 'site/client_custom/scss';
|
const CUSTOM_SCSS_ROOT = 'site/custom/scss';
|
||||||
|
|
||||||
const getFolders = path => {
|
const getFolders = path => {
|
||||||
if (existsSync(path)) {
|
if (existsSync(path)) {
|
||||||
|
|
Loading…
Reference in a new issue