Skip to content

Commit

Permalink
Added client README.md
Browse files Browse the repository at this point in the history
  • Loading branch information
codemonkey800 committed Apr 9, 2021
1 parent 33a26b4 commit 08a9dea
Showing 1 changed file with 72 additions and 0 deletions.
72 changes: 72 additions & 0 deletions client/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,72 @@
# Client

napari hub website implemented with Next.js and TypeScript! We use a lot of
cool frontend tech for the website:

- :zap: [React](https://reactjs.org/) + [Next.js](https://nextjs.org/)
- :crossed_swords: [TypeScript](https://www.typescriptlang.org/)
- :art: [SCSS modules](https://github.com/css-modules/css-modules)
- :nail_care: [Tailwind CSS](https://tailwindcss.com/) for utility styles
- :racing_car: [Tailwind JIT](https://tailwindcss.com/docs/just-in-time-mode) for on-demand Tailwind styles
- :package: [pnpm](https://github.com/pnpm/pnpm) for package management
- :camera_flash: [Jest](https://jestjs.io/) + [React Testing Library](https://testing-library.com/docs/react-testing-library/intro) for unit and snapshot tests
- :performing_arts: [Jest](https://jestjs.io/) + [Playwright](https://github.com/microsoft/playwright) for E2E tests
- :mag: [ESlint](https://eslint.org/) + [Stylelint](https://stylelint.io/) for TypeScript and SCSS linting
- :gear: [Plop](https://plopjs.com/documentation/) for boilerplate automation

## Setup Dev Environment

### Node.js

We use Node.js and various packages on NPM for building napari hub. For
package management, we use [pnpm](https://github.com/pnpm/pnpm).

It's recommended you use NVM so you don't have to manage multiple Node.js versions yourself:

- Bash: [nvm](https://github.com/nvm-sh/nvm)
- Fish: [nvm.fish](https://github.com/jorgebucaran/nvm.fish)
- Zsh: [zsh-nvm](https://github.com/lukechilds/zsh-nvm)

When you have NVM setup, run the following commands:

```sh
# Installs Node.js version defined in `.nvmrc`
nvm install

# Uses project defined Node.js version
nvm use

# Install pnpm globally
npm -g install pnpm

# Install project dependencies
pnpm install
```

## Development Mode

To run the app in development mode, run the following command:

```sh
pnpm dev
```

This will start the Next.js dev server with [fast refresh](https://nextjs.org/docs/basic-features/fast-refresh). Edit some code and watch it update in the browser without having to refresh :heart_eyes:

## Plop Generators

We use [Plop](https://plopjs.com/documentation/) to automate common
boilerplate in the codebase. You can run Plop without any arguments and get a
list of generators you can use:

```sh
pnpm plop
```

If you want to use a specific generator, you can pass the name as the first
argument:

```sh
# Run component generator
pnpm plop component
```

0 comments on commit 08a9dea

Please sign in to comment.