Refactor server startup: elimina segfaults, añade leaflet-workaround
Retira import './segfaults' (workaround de crash obsoleto) y añade leaflet-workaround.js (shims global window/document/navigator para render de Leaflet en servidor). Ajustes menores en publications de FalsePositives y subsUnion.
This commit is contained in:
parent
8281fa3427
commit
2a31435135
5 changed files with 23 additions and 28 deletions
19
imports/startup/server/leaflet-workaround.js
Normal file
19
imports/startup/server/leaflet-workaround.js
Normal file
|
|
@ -0,0 +1,19 @@
|
|||
// imports/startup/server/leaflet-workaround.js
|
||||
global.window = {
|
||||
screen: {
|
||||
deviceXDPI: 1,
|
||||
logicalXDPI: 1
|
||||
}
|
||||
};
|
||||
global.document = {
|
||||
documentElement: {
|
||||
style: {}
|
||||
},
|
||||
createElement: () => {
|
||||
return {};
|
||||
}
|
||||
};
|
||||
global.navigator = {
|
||||
userAgent: 'foo',
|
||||
platform: 'bar'
|
||||
};
|
||||
Loading…
Add table
Add a link
Reference in a new issue