Skip to content

Commit

Permalink
Merge pull request #158 from RDFLib/jamie/next/api-calls
Browse files Browse the repository at this point in the history
Prez Lib API service layer
  • Loading branch information
jamiefeiss authored Apr 3, 2024
2 parents afa5bc0 + a0bf683 commit 24dbc0c
Show file tree
Hide file tree
Showing 66 changed files with 13,790 additions and 60,782 deletions.
36 changes: 22 additions & 14 deletions .github/workflows/push_to_next.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Builds & pushes Storybook to AWS
name: Build & push Storybook & Prez UI demo site to AWS

on:
push:
Expand All @@ -11,29 +11,37 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Setup node
uses: actions/setup-node@v3
uses: actions/checkout@v4
- name: Setup pnpm & install workspace
uses: pnpm/action-setup@v3
with:
node-version: latest
- name: Install and build prez-lib
version: latest
run_install: true
- name: Build prez-lib
working-directory: ./prez-lib
run: |
npm ci
CI=false npm run build
- name: Install and build Storybook
run: CI=false pnpm build
- name: Build prez-components
working-directory: ./prez-components
run: |
npm ci
CI=false npm run build-storybook
run: CI=false pnpm build
- name: Build Storybook
working-directory: ./prez-components
run: CI=false pnpm build-storybook
- name: Build prez-ui
working-directory: ./prez-ui
run: CI=false pnpm generate
- name: Configure AWS credentials
uses: aws-actions/configure-aws-credentials@v2
with:
aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }}
aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
aws-region: ap-southeast-2
- name: Clear S3 bucket
- name: Clear Storybook S3 bucket
run: aws s3 rm s3://${{ secrets.NEXT_STORYBOOK_S3_BUCKET_NAME }} --recursive
- name: Upload Storybook to S3
working-directory: ./prez-components
run: aws s3 cp storybook-static/ s3://${{ secrets.NEXT_STORYBOOK_S3_BUCKET_NAME }} --recursive
- name: Clear Prez UI S3 bucket
run: aws s3 rm s3://${{ secrets.NEXT_PREZUI_S3_BUCKET_NAME }} --recursive
- name: Upload Prez UI to S3
working-directory: ./prez-ui
run: aws s3 cp dist/ s3://${{ secrets.NEXT_PREZUI_S3_BUCKET_NAME }} --recursive
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
node_modules/
4 changes: 3 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,4 +6,6 @@ Now separated into multiple projects for reusability.
- `prez-ui` - [Nuxt](https://nuxt.com/) app using `prez-components` re-exporting components as a layer for running Prez UI instances with `prez-template`. Contains the pages & routing for Prez UI.
- `prez-template` - a Nuxt template for customisable Prez UI themes. Inherits the components & page routing which can be overridden by using Nuxt layers. Intended to published and used as a NPX create template

![New design diagram](design.png)
![New design diagram](design.png)

NOTE: This repo now uses [`pnpm`](https://pnpm.io) - a more performant package manager to replace `npm` - and uses a root workspace to reuse dependencies and local packages.
15 changes: 15 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
{
"name": "prez-ui",
"version": "4.0.0",
"description": "The frontend for Prez, a Linked Data API",
"main": "index.js",
"scripts": {
"start": "pnpm --stream -r start",
"start:dev": "pnpm --stream -r run start:dev",
"clean": "rm -rf .parcel-cache && pnpm -r run clean",
"preinstall": "npx only-allow pnpm"
},
"keywords": [],
"author": "[email protected]",
"license": "BSD-3-Clause"
}
Loading

0 comments on commit 24dbc0c

Please sign in to comment.