Compare commits

..

4 Commits

Author SHA1 Message Date
a85eb48343 1.0.19 2021-01-09 01:48:37 +00:00
7c851b5ed2 fix(core): update 2021-01-09 01:48:36 +00:00
bcd69059f8 1.0.18 2021-01-08 22:08:02 +00:00
acba539a6f fix(core): update 2021-01-08 22:08:01 +00:00
5 changed files with 20 additions and 7 deletions

View File

@ -26,16 +26,28 @@ mirror:
- docker
- notpriv
audit:
auditProductionDependencies:
image: registry.gitlab.com/hosttoday/ht-docker-node:npmci
stage: security
script:
- npmci npm prepare
- npmci command npm install --production --ignore-scripts
- npmci command npm config set registry https://registry.npmjs.org
- npmci command npm audit --audit-level=high --only=prod --production
tags:
- docker
auditDevDependencies:
image: registry.gitlab.com/hosttoday/ht-docker-node:npmci
stage: security
script:
- npmci npm prepare
- npmci command npm install --ignore-scripts
- npmci command npm config set registry https://registry.npmjs.org
- npmci command npm audit --audit-level=high
- npmci command npm audit --audit-level=high --only=dev
tags:
- docker
allow_failure: true
# ====================
# test stage

2
package-lock.json generated
View File

@ -1,6 +1,6 @@
{
"name": "@pushrocks/smartssr",
"version": "1.0.17",
"version": "1.0.19",
"lockfileVersion": 1,
"requires": true,
"dependencies": {

View File

@ -1,6 +1,6 @@
{
"name": "@pushrocks/smartssr",
"version": "1.0.17",
"version": "1.0.19",
"private": false,
"description": "a smart server side renderer supporting shadow dom",
"main": "dist_ts/index.js",

View File

@ -51,6 +51,7 @@ export class SmartSSR {
renderTimeMeasurement.start();
await page.goto(urlArg, {
waitUntil: 'networkidle2',
timeout: 0
});
let screenshotBuffer: Buffer;
@ -66,7 +67,6 @@ export class SmartSSR {
const renderedPageString = pageContent;
resultDeferred.resolve(renderedPageString);
const result = await resultDeferred.promise;
renderTimeMeasurement.stop();

View File

@ -47,11 +47,12 @@ export function serializeFunction(rootNode) {
slotsForMove.push(slot);
});
for (const slot of slotsForMove) {
const slottedLightNodesForMove = [];
slot.assignedNodes().forEach((lightNode) => slottedLightNodesForMove.push(lightNode));
slottedLightNodesForMove.forEach((lightNode) => slot.parentNode.insertBefore(lightNode, slot));
slottedLightNodesForMove.forEach((lightNode) =>
slot.parentNode.insertBefore(lightNode, slot)
);
}
// lets modify the css