chore(org): Work towards passing build
This commit is contained in:
parent
f8fb75ec2f
commit
af35a10c06
9 changed files with 19 additions and 16 deletions
|
@ -4,6 +4,9 @@ export const freeSewingConfig = {
|
|||
index: 'canary_freesewing.dev',
|
||||
key: '589c7a7e4d9c95a4f12868581259bf3a', // Search-only API key
|
||||
},
|
||||
bugsnag: {
|
||||
key: '1b3a900d6ebbfd071975e39b534e1ff5',
|
||||
},
|
||||
monorepo: 'https://github.com/freesewing/freesewing',
|
||||
maxWidth: 2800,
|
||||
}
|
||||
|
|
|
@ -3,10 +3,10 @@ import { appWithTranslation } from 'next-i18next'
|
|||
import React from 'react'
|
||||
import Bugsnag from '@bugsnag/js'
|
||||
import BugsnagPluginReact from '@bugsnag/plugin-react'
|
||||
import process from 'process'
|
||||
import { freeSewingConfig } from 'site/freesewing.config.js'
|
||||
|
||||
Bugsnag.start({
|
||||
apiKey: process.env.BUGSNAG_API_KEY,
|
||||
apiKey: freeSewingConfig.bugsnag.key,
|
||||
collectUserIp: false,
|
||||
plugins: [new BugsnagPluginReact()],
|
||||
})
|
||||
|
|
|
@ -12,7 +12,7 @@ import mdxPaths from 'site/prebuild/mdx.paths.js'
|
|||
|
||||
const MdxPage = (props) => {
|
||||
// This hook is used for shared code and global state
|
||||
const app = useApp()
|
||||
const app = useApp(props)
|
||||
|
||||
/*
|
||||
* Each page should be wrapped in the Page wrapper component
|
||||
|
|
|
@ -5,8 +5,8 @@ import MdxWrapper from 'shared/components/wrappers/mdx'
|
|||
import ReadMore from 'shared/components/mdx/read-more.js'
|
||||
import { jargon } from 'site/jargon.mjs'
|
||||
|
||||
const DocsPage = ({ title, mdx }) => {
|
||||
const app = useApp()
|
||||
const DocsPage = ({ title, mdx, bugsnag }) => {
|
||||
const app = useApp({ bugsnag })
|
||||
|
||||
// We don't need all MDX components here, just ReadMore
|
||||
const components = {
|
||||
|
|
|
@ -6,8 +6,8 @@ import { serverSideTranslations } from 'next-i18next/serverSideTranslations'
|
|||
import Layout from 'site/components/layouts/bare'
|
||||
import PageLink from 'shared/components/page-link'
|
||||
|
||||
const HomePage = () => {
|
||||
const app = useApp()
|
||||
const HomePage = (props) => {
|
||||
const app = useApp(props)
|
||||
// Not using translation for now
|
||||
// const { t } = useTranslation(['homepage', 'ograph'])
|
||||
|
||||
|
|
|
@ -10,8 +10,8 @@ import SusiWrapper from 'site/components/wrappers/susi.js'
|
|||
|
||||
const darkLinkClasses = 'decoration-1 underline text-medium font-medium hover:decoration-2'
|
||||
|
||||
const SignInPage = () => {
|
||||
const app = useApp()
|
||||
const SignInPage = (props) => {
|
||||
const app = useApp(props)
|
||||
const { t } = useTranslation(['suli'])
|
||||
|
||||
const [username, setUsername] = useState('')
|
||||
|
|
|
@ -2,8 +2,8 @@ import Page from 'site/components/wrappers/page.js'
|
|||
import useApp from 'site/hooks/useApp.js'
|
||||
import Popout from 'shared/components/popout.js'
|
||||
|
||||
const TypographyPage = () => {
|
||||
const app = useApp()
|
||||
const TypographyPage = (props) => {
|
||||
const app = useApp(props)
|
||||
|
||||
const p = (
|
||||
<p>
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
import axios from 'axios'
|
||||
import process from 'node:process'
|
||||
import process from 'process'
|
||||
|
||||
/*
|
||||
* Helper methods to interact with the FreeSewing backend
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
import { prebuildMdx } from './mdx.mjs'
|
||||
//import { prebuildStrapi } from './strapi.mjs'
|
||||
import { prebuildStrapi } from './strapi.mjs'
|
||||
import { prebuildNavigation } from './navigation.mjs'
|
||||
import { prebuildContributors } from './contributors.mjs'
|
||||
import { prebuildPatrons } from './patrons.mjs'
|
||||
|
@ -11,9 +11,9 @@ const run = async () => {
|
|||
console.log('in run')
|
||||
const SITE = process.env.SITE || 'lab'
|
||||
if (SITE === 'org') {
|
||||
//const mdxPages = await prebuildMdx(SITE)
|
||||
//const [posts] = await prebuildStrapi(SITE)
|
||||
//prebuildNavigation(mdxPages, posts, SITE)
|
||||
const mdxPages = await prebuildMdx(SITE)
|
||||
const [posts] = await prebuildStrapi(SITE)
|
||||
prebuildNavigation(mdxPages, posts, SITE)
|
||||
} else if (SITE === 'dev') {
|
||||
const mdxPages = await prebuildMdx(SITE)
|
||||
if (process.env.GENERATE_OG_IMAGES) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue