mirror of
https://github.com/billsonnn/nitro-react.git
synced 2024-11-22 22:30:52 +01:00
Changes
This commit is contained in:
parent
8d3c16b624
commit
eb865730bb
@ -52,14 +52,15 @@ export const App: FC<{}> = (props) =>
|
|||||||
throw new Error('NitroConfig is not defined!');
|
throw new Error('NitroConfig is not defined!');
|
||||||
|
|
||||||
const renderer = await PrepareRenderer({
|
const renderer = await PrepareRenderer({
|
||||||
width,
|
width: Math.floor(width),
|
||||||
height,
|
height: Math.floor(height),
|
||||||
resolution: window.devicePixelRatio,
|
resolution: window.devicePixelRatio,
|
||||||
autoDensity: true,
|
autoDensity: true,
|
||||||
backgroundAlpha: 0,
|
backgroundAlpha: 0,
|
||||||
preference: 'webgl',
|
preference: 'webgl',
|
||||||
eventMode: 'none',
|
eventMode: 'none',
|
||||||
failIfMajorPerformanceCaveat: false,
|
failIfMajorPerformanceCaveat: false,
|
||||||
|
roundPixels: true
|
||||||
});
|
});
|
||||||
|
|
||||||
await GetConfiguration().init();
|
await GetConfiguration().init();
|
||||||
@ -143,7 +144,7 @@ export const App: FC<{}> = (props) =>
|
|||||||
return (
|
return (
|
||||||
<div
|
<div
|
||||||
className={classNames(
|
className={classNames(
|
||||||
'w-full h-full overflow-hidden text-base',
|
'w-full h-full overflow-hidden text-base bg-black',
|
||||||
!(window.devicePixelRatio % 1) && '[image-rendering:pixelated]',
|
!(window.devicePixelRatio % 1) && '[image-rendering:pixelated]',
|
||||||
)}
|
)}
|
||||||
>
|
>
|
||||||
|
@ -2,7 +2,11 @@
|
|||||||
"compilerOptions": {
|
"compilerOptions": {
|
||||||
"baseUrl": "./src",
|
"baseUrl": "./src",
|
||||||
"target": "es2022",
|
"target": "es2022",
|
||||||
"lib": ["dom", "dom.iterable", "esnext"],
|
"lib": [
|
||||||
|
"dom",
|
||||||
|
"dom.iterable",
|
||||||
|
"esnext"
|
||||||
|
],
|
||||||
"allowJs": true,
|
"allowJs": true,
|
||||||
"skipLibCheck": true,
|
"skipLibCheck": true,
|
||||||
"esModuleInterop": true,
|
"esModuleInterop": true,
|
||||||
@ -18,8 +22,13 @@
|
|||||||
"noEmit": true,
|
"noEmit": true,
|
||||||
"jsx": "react-jsx",
|
"jsx": "react-jsx",
|
||||||
"paths": {
|
"paths": {
|
||||||
"@layout/*": ["layout/*"]
|
"@layout/*": [
|
||||||
|
"layout/*"
|
||||||
|
]
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"include": ["src", "node_modules/@nitrots/nitro-renderer/src/**/*.ts"]
|
"include": [
|
||||||
|
"src",
|
||||||
|
"node_modules/@nitrots/nitro-renderer/src/**/*.ts"
|
||||||
|
]
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user