mirror of
https://github.com/lovell/sharp.git
synced 2025-07-10 02:50:15 +02:00
Docs: add section about worker threads
This commit is contained in:
parent
e8149f5295
commit
c91373fba3
@ -177,3 +177,10 @@ npx electron-rebuild
|
|||||||
|
|
||||||
Further help can be found at
|
Further help can be found at
|
||||||
[https://electronjs.org/docs/tutorial/using-native-node-modules](https://electronjs.org/docs/tutorial/using-native-node-modules)
|
[https://electronjs.org/docs/tutorial/using-native-node-modules](https://electronjs.org/docs/tutorial/using-native-node-modules)
|
||||||
|
|
||||||
|
## Worker threads
|
||||||
|
|
||||||
|
The main thread must call `require('sharp')`
|
||||||
|
before worker threads are created
|
||||||
|
to ensure shared libraries remain loaded in memory
|
||||||
|
until after all threads are complete.
|
||||||
|
Loading…
x
Reference in New Issue
Block a user