This is the source code for my offical website harrytang.xyz. It is built using Next.js and Tailwind CSS. The backend is built using Strapi.
Install the dependencies:
pnpm install
Next, create a .env.local
file in the root of your project and set the the nessary environment variables.
nodesh # docker run --rm -it -v ${PWD}:/workspace -w /workspace ghcr.io/harrytang/devops-tools:node sh
export $(cat .env.local | grep -v '^#' | xargs)
pnpm run test
To run the e2e tests locally, run the following command:
docker run --rm -it -v ${PWD}:/workspace -w /workspace mcr.microsoft.com/playwright:latest bash
export $(cat .env.e2e.local | grep -v '^#' | xargs)
npm install -g pnpm
pnpm run build
pnpm exec playwright install --with-deps
pnpm run test:e2e
│ Searching for CSS files in the current directory and its subdirectories…
│ ↳ Linked ./tailwind.config.ts
to ./src/styles/tailwind.css
│ Migrating JavaScript configuration files…
│ ↳ The configuration file at ./tailwind.config.ts
could not be automatically migrated to the new CSS configuration format, so your CSS has been updated to load your existing
│ configuration file.
│ Migrating templates…
│ ↳ Migrated templates for configuration file: ./tailwind.config.ts
│ Migrating stylesheets…
│ ↳ Migrated stylesheet: ./src/styles/tailwind.css
│ Migrating PostCSS configuration…
│ ↳ Installed package: @tailwindcss/postcss
│ ↳ Removed package: autoprefixer
│ ↳ Migrated PostCSS configuration: ./postcss.config.js
│ Updating dependencies…
│ ↳ Updated package: prettier-plugin-tailwindcss
│ ↳ Updated package: tailwindcss
│ Verify the changes and commit them to your repository.