blocks-template
blocks-template copied to clipboard
chore: Use setup-node action to cache dependencies
Signed-off-by: jongwooo [email protected]
Details
Updated workflows to cache dependencies using actions/setup-node. setup-node@v3 or newer has caching built-in.
AS-IS
- name: Checkout code
uses: actions/checkout@v3
- name: Install dependencies
run: yarn install
TO-BE
- name: Checkout code
uses: actions/checkout@v3
- name: Set up Node.js
uses: actions/setup-node@v3
with:
node-version: 18.x
cache: yarn
- name: Install dependencies
run: yarn install --immutable
It’s literally a one line change to pass the
cache: yarninput parameter.