Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@ewizardjs/blocks-renderer

Package Overview
Dependencies
Maintainers
0
Versions
6
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@ewizardjs/blocks-renderer

**Module render wiz blocks**

  • 1.3.0
  • latest
  • npm
  • Socket score

Version published
Weekly downloads
29
increased by3.57%
Maintainers
0
Weekly downloads
 
Created
Source

Render Blocks module

Module render wiz blocks

For use module

  • For create puppeteer class instance
const puppeteer = FacadePuppeteer.create();
  • For create page
await puppeteer.createPage(url, requirePuppeteer, { waitUntil: 'networkidle0' });
  • For render only different blocks
  const blocksByTheme = ['blockTheme1', 'blockTheme3']; // optional argument, to render only blocks for current theme email

  await Promise.all([
    await puppeteer.renderBlocks(opts, blocksByTheme),
  ]);
  • For render blocks by window.__blocks
 
  await Promise.all([
    await puppeteer.createRequestInterceptor(opts, 'settings.json'), // optional class method
    await puppeteer.renderBlocks(opts),
  ]);
  • For inject scripts to page
  const editorJS = join(presentationPath, 'build', 'dev', 'editor.js');

  await puppeteer.addedScriptsToPage([editorJS]); // inject any scripts for puppeter page
  • For get data from window puppeteer page
  const { __blocks, __blocksList } = await puppeteer.getWindowData(['__blocks', '__blocksList']);
  • For close Browser
await puppeteer.closeBrowser()

Install

  • npm ci

Develop

  • npm run build
  • npm run build:watch

Run tests

  • npm run test
  • npm run test:debug

FAQs

Package last updated on 06 Sep 2024

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc