Ju99ernaut / grapesjs-template-manager

Template and page manager for grapesjs

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

TypeError from file src/index.js

treborin opened this issue · comments

Hi, new install with this error:
I see in console a TypeError from file src/index.js, here: const res = await cs.loadAll();

M. Firefox browser:
Uncaught (in promise) TypeError: r is null
t index.js:124
l runtime.js:63
_invoke runtime.js:293
P runtime.js:118
Babel 4
Backbone 4
P EditorView.ts:19
setTimeout handlere/P< EditorView.ts:18
2316/i</v/t[e]< Backbone
Le Underscore
Backbone 5
_checkReady Editor.ts:154
Backbone 5
a Editor.ts:196
loadOnStart Editor.ts:214
s grapes.min.js:2
s grapes.min.js:2
v grapes.min.js:2
v grapes.min.js:2
loadOnStart Editor.ts:204
setTimeout handler
n.prototype.loadOnStart Editor.ts:204
init index.js:84
index.html:110

G. Chrome browser:
Uncaught (in promise) TypeError: Cannot read properties of null (reading 'loadAll')
at index.js:124:34
at l (runtime.js:63:40)
at Generator._invoke (runtime.js:293:22)
at Generator.next (runtime.js:118:21)
at n (index.js:3:20)
at s (index.js:25:9)
at index.js:32:7
at new Promise ()
at n. (index.js:21:12)
at y (backbone.js:369:57)

Everything working ok without the grapesjs-project-manager plugin.
It is a fresh install of GrapesJs with these plugins:

    <title>GrapesJS</title>
    <link rel="stylesheet" href="dist/css/grapes.min.css">
    <link rel="stylesheet" href="plugins/templates-manager/dist/css/grapesjs-project-manager.min.css">
    <script src="dist/grapes.min.js" type="text/javascript"></script>
    <script src="plugins/basics/dist/grapesjs-blocks-basic.min.js" type="text/javascript"></script>
    <script src="plugins/templates-manager/dist/js/grapesjs-project-manager.min.js" type="text/javascript"></script>
    <script src="plugins/exports/dist/grapesjs-plugin-export.min.js" type="text/javascript"></script>
    <script src="plugins/navbar/dist/grapesjs-navbar.min.js" type="text/javascript"></script>
    <style>
        fromElement: true,
        pageManager: true, // This should be set to true
        storageManager: {
          id: 'gjs-',             // Prefix identifier that will be used inside storing and loading
          type: 'indexdb',          // Type of the storage
          autosave: true,         // Store data automatically
          autoload: true,         // Autoload stored data on init
          stepsBeforeSave: 1,     // If autosave enabled, indicates how many changes are necessary before store method is triggered
          storeComponents: true,  // Enable/Disable storing of components in JSON format
          storeStyles: true,      // Enable/Disable storing of rules in JSON format
          storeHtml: true,        // Enable/Disable storing of components as HTML string
          storeCss: true,         // Enable/Disable storing of rules as CSS string
        },

Pls, help!

Typo error:
type: 'indexeddb',