Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save nissan/ae64f3c525b98477781588538b5125f5 to your computer and use it in GitHub Desktop.
Save nissan/ae64f3c525b98477781588538b5125f5 to your computer and use it in GitHub Desktop.
Setup a new .NET Core 2.1 app for Windows with React, Storybook, Jest
#Assumes you have the .NET SDK 2.1 for Windows already installed
#Use Chocolatey to install packages, run this script from Administrator Powershell
Set-ExecutionPolicy Bypass -Scope Process -Force
iex ((New-Object System.Net.WebClient).DownloadString('https://chocolatey.org/install.ps1'))
#Use nvm to manage node versions
choco install -y nvm
nvm use default
#install yarn independent of version of node being used
choco install -y yarn
refreshenv
yarn global add @storybook/cli
mkdir sampleApp
cd sampleApp
dotnet new react
cd ClientApp
yarn add --dev react-test-renderer
getstorybook
#Do `../dotnet run` to run app, `yarn test` to run Jest tests or `yarn start storybook` to view stories
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment