Skip to content

Access data dynamicly for relevant sites #73

@jNullj

Description

@jNullj

Currently the manifest requires permision for all urls.
Some users might prefer least needed permisions from the app.
A solution for that might be adding that permision as an optional permission and asking user to add permission for data of new sites added to the extention.

example for making data for domains an optional permission that can be asked later from the running extention at runtime:
manifest.json

...
"optional_permissions": [ "http://*/", "https://*/"  ]
...

example for asking permission for a new site at runtime:

	chrome.permissions.request({
	origins: [protocol +"://"+ domain +":"+ port+"/"]
	}, function(granted) {
		// The callback argument will be true if the user granted the permissions.
		if (granted) {
			alert("amazing things happend here")
		} else {
			alert("Without permision to the site the app can't work")
		}
	});

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions