Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

update tina #486

Closed
wants to merge 4 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions next-env.d.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
/// <reference types="next" />
/// <reference types="next/image-types/global" />
/// <reference types="next/navigation-types/compat/navigation" />

// NOTE: This file should not be edited
// see https://nextjs.org/docs/basic-features/typescript for more information.
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
},
"devDependencies": {
"@svgr/webpack": "^6.3.1",
"@tinacms/cli": "^1.5.14",
"@tinacms/cli": "^1.5.22",
"@types/js-cookie": "^3.0.0",
"@types/node": "^16.11.7",
"@types/react": "^17.0.35",
Expand All @@ -34,7 +34,7 @@
"react-icons": "^4.2.0",
"styled-jsx": "^3.2.5",
"tailwindcss": "^3.2.4",
"tinacms": "^1.5.6",
"tinacms": "^1.5.13",
"typescript": "^4.5.2"
}
}
9 changes: 9 additions & 0 deletions tina/config.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,15 @@ const config = defineConfig({
process.env.NEXT_PUBLIC_VERCEL_GIT_COMMIT_REF! || // Vercel branch env
process.env.HEAD!, // Netlify branch env
token: process.env.TINA_TOKEN!,
ui: {
previewUrl: (context) => {
return {
url: `https://tina-cloud-starter-git-${decodeURIComponent(
context.branch
)}-tinacms.vercel.app/`,
};
},
},
media: {
// If you wanted cloudinary do this
// loadCustomStore: async () => {
Expand Down
2 changes: 1 addition & 1 deletion tina/tina-lock.json

Large diffs are not rendered by default.

11 changes: 9 additions & 2 deletions tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,14 +13,21 @@
"resolveJsonModule": true,
"isolatedModules": true,
"jsx": "preserve",
"incremental": true
"incremental": true,
"plugins": [
{
"name": "next"
}
],
"strictNullChecks": false
},
"exclude": ["node_modules"],
"include": [
"next-env.d.ts",
"**/*.ts",
"**/*.tsx",
".forestry/types.ts",
".forestry/config.ts"
".forestry/config.ts",
".next/types/**/*.ts"
]
}
Loading