You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Even though the bookmarklet does not use "eval" or is an inline-script, it looks like browsers treat it as such. See this SO question and this issue for details.
This CSP also blocks all injected CSS, which I was using to style the popup modal.
Short term fix:
Copy and paste main.js into the console, and hit enter to run. The "success modal" won't display, due to the inline CSS getting blocked by CSP, but you should be able to manually copy and paste the JSON export after plugging this into the console:
Unfortunately, this is not something I can work around, as far a bookmarklet goes. This CSP will block any bookmarklet, period. And you can't simply inject a new meta tag, since the header will override the meta tag if it is more restrictive (details).
The only way forward that I see is to migrate this to an entirely different form, such as a chrome extension. I avoided doing this previously, when I first started building this, since I don't like the level of permissions that extensions require and the associated privacy issues. Technically speaking though, it might not take that much work to wrap the code I have already written into a Chrome Extension. Or maybe as a command line utility or something like that.
The text was updated successfully, but these errors were encountered:
Looks like LinkedIn just implemented CSP (was not there before):
Even though the bookmarklet does not use "eval" or is an inline-script, it looks like browsers treat it as such. See this SO question and this issue for details.
This CSP also blocks all injected CSS, which I was using to style the popup modal.
Short term fix:
Copy and paste
main.js
into the console, and hit enter to run. The "success modal" won't display, due to the inline CSS getting blocked by CSP, but you should be able to manually copy and paste the JSON export after plugging this into the console:Options for moving forward
Unfortunately, this is not something I can work around, as far a bookmarklet goes. This CSP will block any bookmarklet, period. And you can't simply inject a new meta tag, since the header will override the meta tag if it is more restrictive (details).
The only way forward that I see is to migrate this to an entirely different form, such as a chrome extension. I avoided doing this previously, when I first started building this, since I don't like the level of permissions that extensions require and the associated privacy issues. Technically speaking though, it might not take that much work to wrap the code I have already written into a Chrome Extension. Or maybe as a command line utility or something like that.
The text was updated successfully, but these errors were encountered: