next-sanity
Advanced tools
Comparing version 0.8.0-new-preview-mode.3 to 0.8.0
export * from './NextStudio'; | ||
export * from './NextStudioGlobalStyle'; | ||
export * from './NextStudioHead'; | ||
export * from './NextStudioNoScript'; | ||
export * from './ServerStyleSheetDocument'; | ||
export * from './utils'; |
@@ -42,3 +42,7 @@ /// <reference types="react" /> | ||
unstable__noFavicons?: boolean; | ||
/** | ||
* Don't render the <noscript> tag | ||
*/ | ||
unstable__noNoScript?: boolean; | ||
} | ||
export declare const NextStudio: import("react").MemoExoticComponent<({ children, config, unstable__noGlobalStyle, unstable__noTailwindSvgFix, unstable__head, unstable__document_title, unstable__bg, unstable__noFavicons, ...props }: NextStudioProps) => JSX.Element>; | ||
export declare const NextStudio: import("react").MemoExoticComponent<({ children, config, unstable__noGlobalStyle, unstable__noTailwindSvgFix, unstable__head, unstable__document_title, unstable__bg, unstable__noFavicons, unstable__noNoScript, ...props }: NextStudioProps) => JSX.Element>; |
@@ -32,3 +32,3 @@ /// <reference types="react" /> | ||
static getInitialProps(ctx: DocumentContext): Promise<{ | ||
styles: (JSX.Element | import("react").ReactFragment | undefined)[]; | ||
styles: ({} | undefined)[]; | ||
html: string; | ||
@@ -35,0 +35,0 @@ head?: (JSX.Element | null)[] | undefined; |
@@ -15,2 +15,1 @@ import { ProjectConfig } from './types'; | ||
}; | ||
export declare function useParams(params: Params): Params; |
export * from './NextStudio'; | ||
export * from './NextStudioGlobalStyle'; | ||
export * from './NextStudioHead'; | ||
export * from './NextStudioNoScript'; | ||
export * from './ServerStyleSheetDocument'; | ||
export * from './utils'; |
@@ -42,3 +42,7 @@ /// <reference types="react" /> | ||
unstable__noFavicons?: boolean; | ||
/** | ||
* Don't render the <noscript> tag | ||
*/ | ||
unstable__noNoScript?: boolean; | ||
} | ||
export declare const NextStudio: import("react").MemoExoticComponent<({ children, config, unstable__noGlobalStyle, unstable__noTailwindSvgFix, unstable__head, unstable__document_title, unstable__bg, unstable__noFavicons, ...props }: NextStudioProps) => JSX.Element>; | ||
export declare const NextStudio: import("react").MemoExoticComponent<({ children, config, unstable__noGlobalStyle, unstable__noTailwindSvgFix, unstable__head, unstable__document_title, unstable__bg, unstable__noFavicons, unstable__noNoScript, ...props }: NextStudioProps) => JSX.Element>; |
@@ -32,3 +32,3 @@ /// <reference types="react" /> | ||
static getInitialProps(ctx: DocumentContext): Promise<{ | ||
styles: (JSX.Element | import("react").ReactFragment | undefined)[]; | ||
styles: ({} | undefined)[]; | ||
html: string; | ||
@@ -35,0 +35,0 @@ head?: (JSX.Element | null)[] | undefined; |
@@ -15,2 +15,1 @@ import { ProjectConfig } from './types'; | ||
}; | ||
export declare function useParams(params: Params): Params; |
{ | ||
"name": "next-sanity", | ||
"version": "0.8.0-new-preview-mode.3", | ||
"version": "0.8.0", | ||
"description": "Sanity.io toolkit for Next.js", | ||
@@ -30,11 +30,6 @@ "keywords": [ | ||
"./package.json": "./package.json", | ||
"./preview": { | ||
"source": "./src/preview/index.ts", | ||
"require": "./lib/cjs/preview/index.js", | ||
"default": "./lib/esm/preview/index.js" | ||
}, | ||
"./studio": { | ||
"source": "./src/studio/index.ts", | ||
"require": "./lib/cjs/studio/index.js", | ||
"default": "./lib/esm/studio/index.js" | ||
"source": "./src/studio.ts", | ||
"require": "./lib/cjs/studio.js", | ||
"default": "./lib/esm/studio.js" | ||
} | ||
@@ -46,7 +41,4 @@ }, | ||
"*": { | ||
"preview": [ | ||
"./lib/dts/preview/index.d.ts" | ||
], | ||
"studio": [ | ||
"./lib/dts/studio/index.d.ts" | ||
"./lib/dts/studio.d.ts" | ||
] | ||
@@ -63,3 +55,3 @@ } | ||
"prebuild": "npm run clean && node scripts/preParcel.js", | ||
"build": "npm run tsdx build && parcel build && tsc --project tsconfig.build.json", | ||
"build": "npm run tsdx build && parcel build && tsc --declarationDir lib/dts --project tsconfig.studio.json", | ||
"clean": "rimraf lib", | ||
@@ -87,5 +79,3 @@ "coverage": "npm test -- --coverage", | ||
"@sanity/groq-store": "^0.4.0", | ||
"eventsource": "^2.0.2", | ||
"groq": "^2.29.3", | ||
"use-sync-external-store": "^1.2.0" | ||
"groq": "^2.29.3" | ||
}, | ||
@@ -98,8 +88,6 @@ "devDependencies": { | ||
"@types/jest": "^28.1.6", | ||
"@types/react": "^18.0.6", | ||
"@types/react": "^17.0.48", | ||
"@types/react-dom": "^18.0.6", | ||
"@types/styled-components": "^5.1.26", | ||
"@types/use-sync-external-store": "^0.0.3", | ||
"@typescript-eslint/eslint-plugin": "^5.33.0", | ||
"autoprefixer": "^10.4.8", | ||
"eslint": "^8.21.0", | ||
@@ -116,3 +104,2 @@ "eslint-config-next": "^12.2.5", | ||
"parcel": "^2.7.0", | ||
"postcss": "^8.4.16", | ||
"prettier": "^2.7.1", | ||
@@ -126,3 +113,2 @@ "prettier-plugin-packagejson": "^2.2.18", | ||
"styled-components": "^5.3.5", | ||
"tailwindcss": "^3.1.8", | ||
"tsdx": "^0.14.1", | ||
@@ -136,3 +122,3 @@ "typescript": "^4.7.4", | ||
"engines": { | ||
"node": ">=14" | ||
"node": ">=12" | ||
}, | ||
@@ -142,6 +128,3 @@ "targets": { | ||
"distDir": "./lib/cjs", | ||
"source": [ | ||
"./src/studio/index.ts", | ||
"./src/preview/index.ts" | ||
], | ||
"source": "./src/studio.ts", | ||
"outputFormat": "commonjs", | ||
@@ -151,3 +134,3 @@ "isLibrary": true, | ||
"engines": { | ||
"browsers": "chrome 80, safari 15, firefox 90" | ||
"browsers": "chrome 64, safari 12, firefox 62, edge 79" | ||
}, | ||
@@ -158,6 +141,3 @@ "includeNodeModules": false | ||
"distDir": "./lib/esm", | ||
"source": [ | ||
"./src/studio/index.ts", | ||
"./src/preview/index.ts" | ||
], | ||
"source": "./src/studio.ts", | ||
"outputFormat": "esmodule", | ||
@@ -167,3 +147,3 @@ "isLibrary": true, | ||
"engines": { | ||
"browsers": "chrome 80, safari 15, firefox 90" | ||
"browsers": "chrome 64, safari 12, firefox 62, edge 79" | ||
}, | ||
@@ -170,0 +150,0 @@ "includeNodeModules": false |
@@ -217,3 +217,3 @@ # next-sanity<!-- omit in toc --> | ||
> [See it live](https://next.sanity.build/studio) | ||
> [See it live](https://next.sanity.build/) | ||
@@ -220,0 +220,0 @@ The latest version of Sanity Studio allows you to embed a near-infinitely configurable content editing interface into any React application. This opens up many possibilities: |
export * from './NextStudio' | ||
export * from './NextStudioGlobalStyle' | ||
export * from './NextStudioHead' | ||
export * from './NextStudioNoScript' | ||
export * from './ServerStyleSheetDocument' | ||
export * from './utils' |
@@ -138,5 +138,5 @@ import {GroqStore, Subscription} from '@sanity/groq-store' | ||
// Return params that are stable with deep equal as long as the key order is the same | ||
export function useParams(params: Params): Params { | ||
function useParams(params: Params): Params { | ||
const stringifiedParams = useMemo(() => JSON.stringify(params), [params]) | ||
return useMemo(() => JSON.parse(stringifiedParams), [stringifiedParams]) | ||
} |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
4
31
3
246961
71
2060
- Removedeventsource@^2.0.2
- Removeduse-sync-external-store@^1.2.0
- Removeduse-sync-external-store@1.2.2(transitive)