Welcome to the code base for frontendconf.ch. You are very welcome to contribute!
Some notes:
- It is based on
Next.js
and hosted onNow
- The content is hosted on
Contentful
- Since this started as a proof-of-concept, the data handling is rather crude: We are grabbing everything there is from Contentful and transform it to what we want to display on the current page. This will not scale very well, so the next step is to add a reasonable data store and fetching mechanism.
- The styles started within a separate prototype and were merged here as good as possible. However, most of the intentions of the initial CSS structure were probably lost along the way. This will be taken care of as part of the next version. Most probably using
styled components
or a similar approach.
- Use Node version specified in
.nvmrc
(ideally using nvm). - Install dependencies:
npm install
- Start application:
npm start
NOTE: There is an issue on now.sh where the webpack build throws a SIGSEGV when trying to build the CSS on the server. To temporarily work around this, the deploy steps run a pre-deploy script making sure the CSS is generated locally and uploaded as is.
# now switch to FEC Team
now switch
# Deploy
npm run deploy
NOTE: www.frontendconf.ch is redirected to frontendconf.ch
# Point dev.frontendconf.ch to latest deployment (use `now ls` to find DEPLOYMENT_ID)
npm run alias frontendconf-contentful-DEPLOYMENT_ID.now.sh dev.frontendconf.ch
# Point frontendconf.ch to latest deployment (use `now ls` to find DEPLOYMENT_ID)
npm run alias frontendconf-contentful-DEPLOYMENT_ID.now.sh frontendconf.ch
# Dev
npm run logs-dev
# Prod
npm run logs