Go to file
Egor Savkin 1ff79878be Inject JS in templates with correct domains
Signed-off-by: Egor Savkin <es@m-labs.hk>
2024-06-17 16:17:40 +08:00
content Use shortcodes for email links 2024-06-07 17:44:27 +08:00
sass/css Add installer to the main page 2024-06-06 11:10:56 +08:00
server rfq: use password file 2024-01-08 17:53:04 +08:00
static Inject JS in templates with correct domains 2024-06-17 16:17:40 +08:00
templates Inject JS in templates with correct domains 2024-06-17 16:17:40 +08:00
.gitignore feat(place-order): Adds order hardware system 2019-11-06 14:49:00 +08:00
README.md Inject JS in templates with correct domains 2024-06-17 16:17:40 +08:00
Website design specs.docx add design specs document 2019-07-26 21:11:05 +08:00
config.toml Inject JS in templates with correct domains 2024-06-17 16:17:40 +08:00
package-lock.json Fix notification remained visible when side menu is opened 2024-04-09 14:56:05 +08:00
package.json Optimize bundle size, and drop its support for J2ME's Opera (layout doesn't support small screens anyway) 2024-04-09 14:56:05 +08:00
webpack.config.js Inject JS in templates with correct domains 2024-06-17 16:17:40 +08:00

README.md

M-Labs.hk website source code

These instructions will get you a copy of the project up and running on your local machine for development and testing purposes. For deployment, see the nix-scripts repository. Commits to https://git.m-labs.hk/M-Labs/web2019.git are automatically deployed to m-labs.hk through Hydra.

Clone the project:

git clone https://git.m-labs.hk/M-Labs/web2019.git
cd web2019

Install Zola.

Start with targeting m-labs.hk domain:

DOMAINNAME=m-labs.hk zola serve

DOMAINNAME=m-labs.hk can be omitted, since it defaults to m-labs.hk. For any other domains it needs to be set explicitly.

To build the .bundle.js from .jsx files:

nix-shell -p nodejs
npm install
npm run build

Domain handling

Environmental variable DOMAINNAME controls only the following links on the website:

  • email mailto: links
  • hook for the RFQ server (window.API_RFQ) variable

If absent, DOMAINNAME defaults to m-labs.hk.