Quickly navigate from a live web page to its corresponding entry in Contentstack

Latest Version

Version
1.2.5
Update
September 4, 2024
Size
32.92KiB
Developer
contentstack.com
Category
Users
635
Rating
5 ★
Manifest Version
3
Web Store Status
Languages Support
English
See more
Permissions
ActiveTab
DeclarativeContent
Storage
Tabs
Downloads
See more

Contentstack Extension

How does it work?

If you are on a web page of a site that is powered by Contentstack, and if you have the permission to edit its content, you will see an edit button at the right/left bottom of the page. Clicking this button will take you to the corresponding entry in Contenstack, where you can edit the entry.

This eliminates the need to search for specific entries within Contentstack’s web application and provides an intuitive editing experience for users who need to quickly find and update content.


How to set up the extension?

1. Add this extension by clicking on the Add to Chrome button.

2. Once installed, a pop-up will prompt you to enter the stack details, datacenter region (North America, Europe, & Other), and button preferences. Provide the necessary details in each field (all fields are mandatory) and then save the configuration.

3. Add the following attributes to the body tag of your website’s page templates:

a. data-pageref: Used to identify the entry UID of the current page
b. data-contenttype: Used to identify the content type UID of the entry
c. data-locale: Used to identify the local of the entry for the current page

Here’s an example of how to add these details in your code:



In the above example:

\"bltb8b487559a1b715d\" is the UID of the entry
\"product\" is the UID of the content type
\"en-us\" is the locale of the entry of the corresponding web page

4. Go to the tab in your Chrome browser where you want to use this extension, and reload or refresh the page.
Note: This is a one-time activity when you add a new domain or an API key.

5. The Edit button will now be visible on your Contentstack-powered web pages.

For more details on the extension, visit our GitHub page: https://github.com/contentstack/contentstack-chrome-extension.git
Read more

Source Manifest.json

{"update_url": "https://clients2.google.com/service/update2/crx", "manifest_version": 3, "name": "Contentstack", "version": "1.2.5", "description": "Quickly navigate from a live web page to its corresponding entry in Contentstack", "icons": { "16": "images/logo16.png", "32": "images/logo32.png", "48": "images/logo48.png", "128": "images/logo128.png" }, "permissions": [ "activeTab", "declarativeContent", "storage", "tabs", "downloads" ], "background": { "service_worker": "background.js", "type": "module" }, "content_scripts": [ { "matches": [ "http://*/*", "https://*/*" ], "run_at": "document_end", "js": ["content-script.js"] } ], "action": { "default_popup": "options.html", "default_icon": { "16": "images/logo16.png", "32": "images/logo32.png", "48": "images/logo48.png", "128": "images/logo128.png" } }, "options_ui": { "page": "options.html", "open_in_tab": false }}
Read more