pricing-components

Pricing components for the Jimdo cosmos.

Usage no npm install needed!

<script type="module">
  import pricingComponents from 'https://cdn.skypack.dev/pricing-components';
</script>

README

Pricing Component

A central pricing component for all of Jimdo.

Owned by the Growth team, reach us at #growthteam.

For devs

This section describes tools and conventions to be aware of.

Setup highly informed by: https://blog.harveydelaney.com/creating-your-own-react-component-library/

Git hooks

A number of action taken through Git are hooked into for automation. For this we use husyk and cofigure hooks in the "husky" section of our package.json. Overview of our hooks:

  • Commits, are linted for format.
  • Commits, automatically apply code-formatting.

Commit Message format

This repo follows conventional commits with loos rules on casing and you being free to end subjects with a ".". If you are new to this read more about commitlint.

Commit message linting rules are defined in commitlint.config.js, using a .js file to add comments. For reading up on the configuration options of commitlint we recommand the docs on GitHub which are much more readable than the overly dark website.

Conventional commit message formats ensure that developers can easily understand what kind of changes happened last. They also enable automation for release notes and version computation which we think are two things no developer should have to do manually.

Code formatting

This repo uses Prettier for code formatting. Corresponding rules can be found in .prettierrc. Your Editor and our commit hook should ensure that your code follows this repos conventions.

We belive in code formatting as a strong contribution to code readability for all developers. Always looking at the same format makes it easier to see partters and grasp what new code is doing.

Bundling

This repo uses Rollup for bundling of its components. With this we follow a general trend in the React community to:

Use Webpack for apps, and Rollup for libraries!

Rollup is configured through rollup.config.js.

Great reads on the subject of Rollup vs. Webpack include:

CI setup

This project is build using TravisCI. For this multiple things are setup in and around the codebase.

Travis.yml

In .travis.yml we specify stages to be run on PRs and merges to main. These stages build and publish our library.

NVM

Jimdos TravisCI integrations are setup to rely on nvm for node version management. To profit from the general existance of this setup we have a .nvmrc. It is only used for Ci though, feel free to ignore it during development.

Credentials

To publish our npm package through the private account we need credentials in the CI environment. By adding the tag "travis-config-npm-publish" to our repo on GitHub, Jimdos systems know to inject the required credentials into the CI environment.