* Added ability to change favicon in config * Turned back version of icon in index.twig * Added opportunity to upload favicon and route to get saved favicon * Removed favicon from .codexdocsrc.sample * Added docs to favicon route * Replaced uploadFavicon to initiating /favicon route, updated function, added catching errors from uploadFile * Updated Readme, added info about setting up app * Updated Readme.md * Some changes * Favicon data saves to app.locals, replaced uploading favicon to app.ts * Changed naming in config, from faviconURL to favicon, changed using app.locals variables * Renamed uploadFavicon to downLoadFavicon, removed log in locals.ts * Renamed favicon variable in app.ts * Added checking favicon before uploading function, removed passing locals to views * Added timeout for uploading favicon request and writeFileSync changed to writeFile * Removed passing favicon locals and turned back removed variables * Turned back variables * Fixed duplicating os.tmpdir * Fixed braces in objects, added new lines * Added default favicon path, if favicon does not exists in config * Updated docs, fixed using local favicon |
||
---|---|---|
.github | ||
config | ||
docker | ||
public | ||
src | ||
.codexdocsrc.sample | ||
.dockerignore | ||
.editorconfig | ||
.env.sample | ||
.eslintignore | ||
.eslintrc | ||
.gitignore | ||
.nvmrc | ||
.postcssrc | ||
docker-compose.yml | ||
LICENSE | ||
package-lock.json | ||
package.json | ||
README.md | ||
tsconfig.json | ||
webpack.config.js | ||
yarn.lock |
CodeX Docs
CodeX Docs is a simple but powerful documentation engine for CodeX powered with Editor.js.
You can use CodeX Docs for product documentation, for internal team docs, or for any other documentation.
Development
Prerequisites
- NodeJS (v16.x)
- npx (installed by default with npm)
- Yarn
Install npm packages
yarn install --frozen-lockfile
Create config file
cp .codexdocsrc.sample .codexdocsrc
cp .env.sample .env
Run application (both frontend and backend)
yarn dev
Then you can open browser and navigate to http://localhost:3000.
Now you can authenticate in the application and start creating your documentation.
Available scripts
Start whole application (backend and frontend in watch mode)
yarn dev
Start backend in development mode
yarn start-backend
Compile TypeScript files
yarn compile
Build frontend
To build frontend sources run the following command:
yarn build-frontend
To build frontend and watch for changes run the following command:
yarn build-frontend:dev
Run ESLint with --fix
option
yarn lint
Run tests
yarn test
Setup
You can configure application using configs in /config
directory.
Property | Role |
---|---|
port |
to set port of application |
database |
to name directory with data |
rcFile |
to set destination of codexdocsrc config file |
uploads |
to set destination of directory to save uploads |
secret |
to set secret |
favicon |
to set url or favicon path (favicon need to be in /public directory), like /myFavicon.png , to get favicon. Server uploads file by url and saves it to temporary directory. And you can get favicon by /favicon static route of application |
You can configure application using configs in /config
directory.
Authentication
To manage pages you need to authorize (available on /auth
).
To set password, set the PASSWORD
environment variable inside the .env
file.
Release process
We use release-drafter to generate release notes and GitHub release. It will automatically generate draft release based pull requests data between current version and previous version. To make new release you need go to releases page find the latest draft release and mark it as ready. After creating new release, new git tag will be created and new version will be published.
About CodeX
CodeX is a team of digital specialists around the world interested in building high-quality open source products on a global market. We are open for young people who want to constantly improve their skills and grow professionally with experiments in cutting-edge technologies.
🌐 | Join 👋 | ||
---|---|---|---|
codex.so | codex.so/join | @codex_team | @codex_team |