Skip to content
This repository has been archived by the owner on Sep 26, 2024. It is now read-only.

Commit

Permalink
Niloofar/83822/gatsby migration to v5 (#5646)
Browse files Browse the repository at this point in the history
* refactor: node18, react18 and gatsby5 migration

* fix: robot.txt file is changed when compared from production

* refactor: replace react helmet with gatsby head api

* fix: page direction issue

* fix: glitches in market page

* build: triger build

* refactor: replace helmet with gatsby head in options pages

* build: regenerate package-lock

* docs: added react 18 development guide

* docs: update documentation

* fix: options page error

* fix: fix issue where gatsby 5 bundles all files into one chunk

* build: trigger build

* fix: build error

* fix: createroot not found issue

* fix: scroll issue in signup and check email

* fix: seo issue in some of the routes

* fix: scroll issue in deriv prime and markets

* fix: seo issue

* fix: seo issue in 404 and some other pages

* fix: seo script issues

* fix: seo issues

* fix: eu site has extra credit & debit cards section

* fix: search input auto focus issue

* fix: search input auto focus issue

* build: trigger build

---------

Co-authored-by: niloofar sadeghi <[email protected]>
Co-authored-by: adrienne-rio <[email protected]>
  • Loading branch information
3 people authored Sep 18, 2023
1 parent 7cf6c1c commit d415cbd
Show file tree
Hide file tree
Showing 225 changed files with 5,401 additions and 6,072 deletions.
9 changes: 8 additions & 1 deletion .babelrc
Original file line number Diff line number Diff line change
@@ -1,4 +1,11 @@
{
"presets": ["babel-preset-gatsby"],
"presets": [
[
"babel-preset-gatsby",
{
"stage": "build-javascript" // This fixes the code splitting issue, refer https://github.com/gatsbyjs/gatsby/issues/35731
}
]
],
"plugins": ["@loadable/babel-plugin"]
}
2 changes: 1 addition & 1 deletion .github/workflows/beta.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ jobs:
- name: Setup Node
uses: actions/setup-node@v3
with:
node-version: '16.x'
node-version: '18.x'
cache: 'npm'

- run: npm ci
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/corewebvitals.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ jobs:
- name: Set up Node.js
uses: actions/setup-node@v2
with:
node-version: 14
node-version: 18

- name: Install dependencies
run: npm ci
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ jobs:
- name: Set up Node.js
uses: actions/setup-node@v1
with:
node-version: 16
node-version: 18
- name: Cache dependencies
id: cache
uses: actions/cache@v2
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/production.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ jobs:
- name: Setup Node
uses: actions/setup-node@v3
with:
node-version: '16.x'
node-version: '18.x'
cache: 'npm'

- name: Set version env variable
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/staging.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ jobs:
- name: Setup Node
uses: actions/setup-node@v3
with:
node-version: '16.x'
node-version: '18.x'
cache: 'npm'

- run: npm ci
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/translation-delete.yml
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ jobs:
- name: Setup Node
uses: actions/[email protected]
with:
node-version: '16.x'
node-version: '18.x'
- name: Installing Crowdin
run: npm i -g @crowdin/[email protected]
- name: Delete Branch [${{ github.event.workflow_run.head_branch }}] 🗑️
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/translation-push.yml
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ jobs:
- name: Setup Node
uses: actions/[email protected]
with:
node-version: '16.x'
node-version: '18.x'
- name: Installing Crowdin
run: npm i -g @crowdin/[email protected]
- name: Download New Translations ⬇️
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/translation-sync.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ jobs:
- name: Setup Node
uses: actions/[email protected]
with:
node-version: '16.x'
node-version: '18.x'
- run: npm i -g @crowdin/[email protected]
- name: Fetch Crowdin Master Translation ⬇️
run:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/translation.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ jobs:
- name: Setup Node
uses: actions/[email protected]
with:
node-version: '16.x'
node-version: '18.x'

- run: npm i -g @crowdin/cli
- run: npm ci
Expand Down
7 changes: 4 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

Deriv.com - An online trading platform that offers a wide selection of derivatives to trade on 24/7.

![GitHub Workflow Status](https://img.shields.io/github/workflow/status/binary-com/deriv-com/Release%20Staging) ![node](https://img.shields.io/badge/node-%3E%3D12.3.0-blue.svg) ![npm](https://img.shields.io/badge/npm-%3E%3D6.9.0-blue.svg) [![GATSBY](https://img.shields.io/badge/Gatsby-663399?style=flat&logo=gatsby&logoColor=white)](https://github.com/styled-components/styled-components) [![style: styled-components](https://img.shields.io/badge/style-%F0%9F%92%85%20styled--components-orange.svg?colorB=daa357&colorA=db748e)](https://github.com/styled-components/styled-components) ![Sonar Tech Debt](https://img.shields.io/sonar/tech_debt/binary-com_deriv-com?server=https%3A%2F%2Fsonarcloud.io)
![GitHub Workflow Status](https://img.shields.io/github/workflow/status/binary-com/deriv-com/Release%20Staging) ![node](https://img.shields.io/badge/node-%3E%3D18.12.1-blue.svg) ![npm](https://img.shields.io/badge/npm-%3E%3D8.19.2-blue.svg) [![GATSBY](https://img.shields.io/badge/Gatsby-663399?style=flat&logo=gatsby&logoColor=white)](https://github.com/styled-components/styled-components) [![style: styled-components](https://img.shields.io/badge/style-%F0%9F%92%85%20styled--components-orange.svg?colorB=daa357&colorA=db748e)](https://github.com/styled-components/styled-components) ![Sonar Tech Debt](https://img.shields.io/sonar/tech_debt/binary-com_deriv-com?server=https%3A%2F%2Fsonarcloud.io)
![Sonar Violations (short format)](https://img.shields.io/sonar/violations/binary-com_deriv-com?server=https%3A%2F%2Fsonarcloud.io)

## In this document:
Expand Down Expand Up @@ -34,8 +34,8 @@ Deriv.com - An online trading platform that offers a wide selection of derivativ

Before running or contribute to this project, you need to have the setup of the following packages in your environment

- node >=16.6.0
- npm >=8.11.0
- node >=18.12.1
- npm >=8.19.2
- git (for `contribution`)
- gatsby-cli (npm install -g gatsby-cli) (for using commands that aren't listed in scripts)

Expand Down Expand Up @@ -264,6 +264,7 @@ If preferable to use manual deployment, you can use [gh-pages](https://pages.git
This will be deployed to name.github.io/deriv-com/br/fix_all_the_bugs
⚠️ You have to enable pathPrefix in gatsby-config for manual deployment, otherwise, the resources will not be uploaded to the site
## FAQ
- [how to create a new page?](documents/implementation-guide.md#create-new-page)
Expand Down
Loading

0 comments on commit d415cbd

Please sign in to comment.