Skip to content

Commit

Permalink
Merge pull request #148 from episerver/release/1.0.0
Browse files Browse the repository at this point in the history
Release/1.0.0
  • Loading branch information
epi-qang2 authored Sep 5, 2024
2 parents fc7f0e9 + d4e30fb commit 0bdda99
Show file tree
Hide file tree
Showing 371 changed files with 92,752 additions and 348 deletions.
45 changes: 36 additions & 9 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,13 @@ on:
branches:
- master
- develop
- feature/*
- bugfix/*
- release/**
pull_request:
branches: [ "develop" ]
branches:
- "*"
- master
- feature/**
- release/**

permissions:
contents: write
Expand All @@ -18,9 +21,11 @@ permissions:
env:
NPM_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
AZURE_TOKEN: ${{ secrets.AZURE_TOKEN }}
JIRA_USERNAME: ${{ secrets.JIRA_BOT_USERNAME }}
JIRA_PASSWORD: ${{ secrets.JIRA_BOT_PASSWORD }}

jobs:
build:
build_test_pack:
name: Build, test, and publish
runs-on: windows-latest
env:
Expand All @@ -33,13 +38,13 @@ jobs:
steps:
- name: Checkout repository
uses: actions/checkout@v3

- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node-version }}
cache: 'npm'
cache: "npm"

- name: Setup dependencies
run: npm ci

Expand All @@ -55,5 +60,27 @@ jobs:
${{ github.workspace}}/build/get-versionSuffix.ps1 ${{env.BRANCH_NAME}} ${{github.RUN_NUMBER}}
- name: Publish
if: ${{ github.ref == 'refs/heads/master' }}
run: npm run publish
if: ${{ contains(github.ref,'release/') || github.ref == 'refs/heads/master'}}
run: npm run publish

jira-release:
if: ${{ contains(github.ref,'release/') }}
runs-on: windows-latest
name: Get release version & create JIRA release
needs: build_test_pack
steps:
- name: Checkout repository
uses: actions/checkout@v1

- name: Get release version
uses: episerver/addons-jira-automation/releaseversion@v1
id: branchVersion

- name: Create JIRA release
uses: episerver/addons-jira-automation/release@v1
with:
jira-project: AFORM
jira-package: Optimizely.Forms.Headless.Js.Sdk
jira-host: jira.sso.episerver.net
version: ${{ steps.branchVersion.outputs.manifestSafeVersionString }}
versionSuffix: ${{needs.build_test_pack.outputs.versionSuffix}}
10 changes: 9 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -5,4 +5,12 @@ obj/
App_Data/
.vs/
.vscode/
coverage/
coverage/

/samples/musicfestival-backend-dotnet/modules/_protected/
!samples/musicfestival-backend-dotnet/App_Data/

/samples/netcoreapp/
/samples/epiCloud/
/samples/musicfestival-frontend-react/build/
/samples/musicfestival-backend-dotnet/App_Data/
14 changes: 7 additions & 7 deletions .npmrc
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
@episerver:registry=https://pkgs.dev.azure.com/EpiserverEngineering/netCore/_packaging/headless_forms_beta/npm/registry/
@episerver:registry=https://pkgs.dev.azure.com/EpiserverEngineering/netCore/_packaging/HeadlessForms/npm/registry/
always-auth=true
; begin auth token
//pkgs.dev.azure.com/EpiserverEngineering/netCore/_packaging/headless_forms_beta/npm/registry/:username=Phu.nguyen
//pkgs.dev.azure.com/EpiserverEngineering/netCore/_packaging/headless_forms_beta/npm/registry/:_password=${AZURE_TOKEN}
//pkgs.dev.azure.com/EpiserverEngineering/netCore/_packaging/headless_forms_beta/npm/registry/:email=Phu.nguyen@optimizely.com
//pkgs.dev.azure.com/EpiserverEngineering/netCore/_packaging/headless_forms_beta/npm/:username=Phu.nguyen
//pkgs.dev.azure.com/EpiserverEngineering/netCore/_packaging/headless_forms_beta/npm/:_password=${AZURE_TOKEN}
//pkgs.dev.azure.com/EpiserverEngineering/netCore/_packaging/headless_forms_beta/npm/:email=Phu.nguyen@optimizely.com
//pkgs.dev.azure.com/EpiserverEngineering/netCore/_packaging/HeadlessForms/npm/registry/:username=${AZURE_USERNAME}
//pkgs.dev.azure.com/EpiserverEngineering/netCore/_packaging/HeadlessForms/npm/registry/:_password=${AZURE_TOKEN}
//pkgs.dev.azure.com/EpiserverEngineering/netCore/_packaging/HeadlessForms/npm/registry/:email=${AZURE_EMAIL}
//pkgs.dev.azure.com/EpiserverEngineering/netCore/_packaging/HeadlessForms/npm/:username=${AZURE_USERNAME}
//pkgs.dev.azure.com/EpiserverEngineering/netCore/_packaging/HeadlessForms/npm/:_password=${AZURE_TOKEN}
//pkgs.dev.azure.com/EpiserverEngineering/netCore/_packaging/HeadlessForms/npm/:email=${AZURE_EMAIL}
; end auth token
23 changes: 19 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,10 @@

This is a JS SDK package that helps render a form based on metadata taken from the Headless Form API. In this package, there are 2 main parts:

| Project | Description |
| --------------------------------| ------------------------|
| @episerver/forms-sdk | JS SDK for models, client validation, form loader, form dependencies, form submit |
| @episerver/forms-react | React SDK for rendering a form as a React component |
| Project | Description | Doc |
| --------------------------------| ------------------------| ------------------------|
| @episerver/forms-sdk | JS SDK for models, client validation, form loader, form dependencies, form submit | https://github.com/episerver/content-headless-form-js-sdk/tree/develop/src/%40episerver/forms-sdk#readme
| @episerver/forms-react | React SDK for rendering a form as a React component | https://github.com/episerver/content-headless-form-js-sdk/tree/develop/src/%40episerver/forms-react#readme

ref: https://docs.developers.optimizely.com/content-management-system/v1.2.0-forms/docs/get-started-with-headless-optimizely-forms
## Getting Started
Expand Down Expand Up @@ -44,6 +44,10 @@ Install from the command line
npm run setup
```

To setup musicfestival:
- https://github.com/episerver/content-headless-form-js-sdk/tree/develop/samples/musicfestival-backend-dotnet
- https://github.com/episerver/content-headless-form-js-sdk/tree/develop/samples/musicfestival-frontend-react

3. Build all projects

```sh
Expand All @@ -56,12 +60,23 @@ Install from the command line
npm run start-backend
```

for musicfestival sample site

```sh
npm run start-musicfestival-backend
```
5. Start react site

```sh
npm run start-frontend
```

for musicfestival sample site

```sh
npm run start-musicfestival
```

### View site on browser

Create a form with some elements in MainContentArea of Start page.
Expand Down
Loading

0 comments on commit 0bdda99

Please sign in to comment.