satelllte / displacement Goto Github PK
View Code? Open in Web Editor NEW▶▶▶ Moved into https://github.com/satelllte/displacementx | Displacement maps generator
Home Page: https://xdisplacement.netlify.app
License: GNU General Public License v3.0
▶▶▶ Moved into https://github.com/satelllte/displacementx | Displacement maps generator
Home Page: https://xdisplacement.netlify.app
License: GNU General Public License v3.0
ctx.canvas.width
, ctx.canvas.height
instead of separate width
, height
argumentswidth
, height
argumentsCommunication between UI app and WASM should be done through Worker which runs in a separate thread allowing to render 8k images without freeze, control render loading state, etc.
Checklist:
{{PR_ID}}.example.com
main
branch: deploys to example.com
Some options to review / choose from:
Conditions:
Something like this:
// worker extension type
interface ExtendedWorker<MessageEventType> extends Worker {
onmessage: ((ev: MessageEvent<MessageEventType>) => void) | null
postMessage(message: MessageEventType, transfer: Transferable[]): void
postMessage(message: MessageEventType, options?: StructuredSerializeOptions): void
// ...
}
// usage
type MyWorker = ExtendedWorker<MyMessageType>
Try Vitest
Offline detection can be implemented using:
useEffect(() => {
// TODO: notify user that the app is available for offline use
// ...
// https://developer.chrome.com/docs/workbox/modules/workbox-window/#register-a-service-worker-and-notify-the-user-the-very-first-time-that-service-worker-is-active
// @ts-ignore
const wb = window.workbox
// @ts-ignore
wb.addEventListener('activated', (event) => {
if (!event.isUpdate) {
console.info('WB | activated | event: ', event)
// READY FOR OFFLINE USE !!!!!!
// do something with it ....
}
})
}, [])
Workbox docs reference: https://developer.chrome.com/docs/workbox/modules/workbox-window/#register-a-service-worker-and-notify-the-user-the-very-first-time-that-service-worker-is-active
To turn off page reload after getting back online, reloadOnOnline: false
can be set in next-pwa
config: https://github.com/shadowwalker/next-pwa#available-options
Resolve the following pipeline:
On CI, put NEXT_CI_BUILD = "true"
environment variable
In next.config.js
conditionally ignore:
Setup more strict linting rules for ./src/**/*.tsx?
files
Inter
variable font from CDNGitHub Action: https://github.com/marketplace/actions/lighthouse-check
Netlify custom draft URL: https://answers.netlify.com/t/custom-draft-urls-for-manual-deploys/10888/2
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.