GithubHelp home page GithubHelp logo

smartive / smartive.ch Goto Github PK

View Code? Open in Web Editor NEW
121.0 11.0 26.0 1.38 GB

Our Website—The Best One Yet!

Home Page: https://smartive.ch

JavaScript 1.20% CSS 0.36% TypeScript 98.44%
react javascript nextjs tailwindcss typescript

smartive.ch's Introduction

smartive.ch

Setup

Make sure to create an .env.local file in the project root with all the secret env variables which can be found in 1Password under smartive.ch Secret Env Vars.

  1. nvm use
  2. npm ci
  3. npm run develop

Contributing

Some of the most important information if you are about to contribute. Enjoy.

DatoCMS

We use DatoCMS as a headless CMS. You can find the admin interface here: cms.smartive.ch. If you need access, please contact the webmasters role.

We use GraphQL to query the data from DatoCMS. Types are generated automatically with npm run generate. Type generation is also run on npm run develop, so you don't have to worry about it.

Note: Currently not all content is managed in DatoCMS. Some content is still managed in the codebase. This will be changed in the future. We are working on it! 👷

Next.js

Next.js is used as a framework. Start a development server with npm run develop. 🚀

Code Quality

Automated Tools

We use a set of tools for a reasonably high code quality.

  1. Prettier for Code Formatting npm run prettier
  2. ESLint for Code Guidelines npm run lint
  3. TypeScript for Static Type Checking (done by Next)

These checks are also run on every merge request, and each of these must pass for the MR to be mergable.

Integration Tests

We render all our pages automatically with Playwright to check for errors.

To run the tests locally make sure the development build is running with npm run develop and then start the tests with npm run test.

Conventions

Four Eye Principle

The default main branch is protected and nobody can commit to it. Every feature or bugfix is done in a separate Merge Request, which needs to pass the automated tests and needs to be reviewed by another developer.

NO SELF-MERGES 😜

Naming Conventions

Since we're using an automated release tool (see Releases & Deployment) our Merge Requests need to have a common naming pattern:

type: MESSAGE.

Example:

feat: Add Profile Image Upload for Users.

The following types exist:

feat: A new feature
fix: A bug fix
docs: Documentation only changes
style: Changes that do not affect the meaning of the code (white-space, formatting, missing semi-colons, etc)
refactor: A code change that neither fixes a bug nor adds a feature
perf: A code change that improves performance
test: Adding missing or correcting existing tests
chore: Changes to the build process or auxiliary tools and libraries such as documentation generation

Architecture

This is a React app with server-side rendering provided by Next.js.

Deployment Model

We follow loosely the Gitlab Flow. All our Merge Requests are merged against our default branch main and are automatically deployed to our production system on Vercel.

smartive.ch's People

Contributors

benjaminbrossi avatar buehler avatar celine-s avatar deniaz avatar lboesch avatar matthias714 avatar mfeltscher avatar mircostraessle avatar nadiaposch avatar petermanser avatar renovate-bot avatar virth avatar walkeezy avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.