Issue #2178Opened August 1, 2019by jeffgipson0 reactions

loading remote data

Question

Im working on a project and having a hard time getting remote data. Code:

storageManager: { id: 'gjs-', // Prefix identifier that will be used on parameters type: 'remote', // 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, storeStyles: true, contentTypeJson: true, urlStore: "/api/v1/templates/" + temp_id, urlLoad: "/api/v1/templates/" + temp_id,

Sample response from network tab in dev tools: {"data":{"id":"3","type":"templates","attributes":{"gjs-html":"\u003cdiv\u003etest12324\u003c/div\u003e","gjs-css":"div{color:red;}","name":"Sample","author":"Jeff Gipson","content":"\u003ch1\u003ePut your title here\u003c/h1\u003e\u003ch1\u003eThis is a test 2\u003c/h1\u003e\u003ch1\u003e\u003c/h1\u003e","contact-id":1}}

Thanks for your help: Once we go live I will be supporting this app

Answers (3)

miky9585August 5, 20190 reactions

I think you need to print your data->attributes. Here my printed data that works fine screencapture-localhost-8090-pages-load-2019-08-05-11_11_49

jeffgipsonAugust 6, 20190 reactions

Thanks for the reply @miky9585 I tried this but not working

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...

Browse Plugin Categories

Jump directly to plugin category pages on the marketplace.