Skip to content

Commit

Permalink
crx v1.1.1 (#28)
Browse files Browse the repository at this point in the history
Co-authored-by: Dimitris Grammatikogiannis <dg@dgrammatiko.dev>
  • Loading branch information
rviscomi and dgrammatiko committed Jun 20, 2023
1 parent 2770fff commit 9c40a1d
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 6 deletions.
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -398,4 +398,5 @@ FodyWeavers.xsd
*.sln.iml

# Other
crx.zip
crx.zip
.DS_STORE
2 changes: 1 addition & 1 deletion capo.js
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ function isPreload(element) {
}

function isDeferScript(element) {
return element.matches('script[src][defer]') || element.matches('script:not([src][async])[src][type=module]');
return element.matches('script[src][defer], script:not([src][async])[src][type=module]');
}

function isPrefetchPrerender(element) {
Expand Down
4 changes: 2 additions & 2 deletions crx/chrome.js
Original file line number Diff line number Diff line change
Expand Up @@ -141,7 +141,7 @@ function capo() {
}

function isSyncScript(element) {
return element.matches('script:not([src][defer],[src][async],[type*=json])')
return element.matches('script:not([src][defer],[src][type=module],[src][async],[type*=json])')
}

function isSyncStyles(element) {
Expand All @@ -153,7 +153,7 @@ function capo() {
}

function isDeferScript(element) {
return element.matches('script[src][defer]');
return element.matches('script[src][defer], script:not([src][async])[src][type=module]');
}

function isPrefetchPrerender(element) {
Expand Down
4 changes: 2 additions & 2 deletions crx/manifest.json
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
{
"manifest_version": 3,
"name": "Capo: get your <head> in order",
"description": "Visualize how optimal the ordering of the <head> element is on any web page.",
"version": "1.0.0",
"description": "Visualize the optimal ordering of <head> elements on any web page",
"version": "1.1.1",
"permissions": [
"scripting",
"activeTab"
Expand Down

0 comments on commit 9c40a1d

Please sign in to comment.