Issue #1337πŸ’¬ AnsweredOpened August 4, 2018by mgebeily0 reactions

Loading from package in TypeScript giving undefined error.

Quick answerby artf

It's happening just because grapesjs-preset-newsletter uses an old way of loading the plugin, I'll fix it soon

Read full answer below ↓

Question

Similar to issue #902 but I can't seem to resolve with the steps taken in that discussion. I'm using the latest version of Angular, Webpack, and TypeScript. I'm able to get the editor itself up fine. However, when I try to import grapesjs-preset-newsletter, I'm getting grapesjs is not defined. My imports look like this: Then, in ngOnInit, I'm calling: This doesn't load the preset. The interesting thing is if I have grapesjsNewsletters anywhere in my code, I get grapesjs is not defined. Am I missing something blatant about how webpack or TypeScript imports work with grapesjs presets? Thank you...

Answers (3)

artfβ€’ August 9, 2018

It's happening just because grapesjs-preset-newsletter uses an old way of loading the plugin, I'll fix it soon

devexcelsiorβ€’ April 15, 2019

Im having the same issue, was this ever resolved?

lock[bot]β€’ April 15, 2020

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

Related Questions and Answers

Continue research with similar issue discussions.

Paid Plugins That Match This Issue

Curated by issue keywords and label relevance to help you ship faster.

View all plugins

Loading paid plugin recommendations...

Free option

Check the open-source GrapesJS plugins on GitHub or run a quick search in our free catalog.

Browse free plugins β†’
Premium option

Premium plugins ship with support, regular updates, and production-ready features β€” save days of integration work.

Browse premium plugins β†’

Related tutorials

In-depth guides on the same topic.

All tutorials β†’

Browse Plugin Categories

Jump directly to plugin category pages on the marketplace.