Skip to content

Commit

Permalink
Merge 1aba77f into 4a3f5e3
Browse files Browse the repository at this point in the history
  • Loading branch information
wupengFEX committed Jan 8, 2018
2 parents 4a3f5e3 + 1aba77f commit 40ac8eb
Showing 1 changed file with 10 additions and 20 deletions.
30 changes: 10 additions & 20 deletions rules.json
Original file line number Diff line number Diff line change
Expand Up @@ -53,31 +53,25 @@
},
"link": {
"mandatory": [{
"rel": "/^(miphtml)|(canonical)|(standardhtml)$/"
"rel": "/^(canonical)|(standardhtml)$/"
}, {
"rel": "/^stylesheet$/",
"href": "/^(https:)?\/\/(mipcache.bdstatic.com\/static\/mipmain)|(m.baidu.com\/static\/ala\/sf\/static\/)|((https:)?\/\/mipcache.bdstatic.com\/static\/v\\d\/)|((https:)?\/\/c.mipcdn.com\/static\/v\\d\/)|((https:)?\/\/c.mipcdn.com\/static\/mipmain)/"
"href": "/^(https:)?\/\/((mipcache\\.bdstatic\\.com\/static\/mipmain-v\\d\\.\\d\\.\\d\\.css)|(c\\.mipcdn\\.com\/static\/mipmain-v\\d\\.\\d\\.\\d\\.css)|(mipcache\\.bdstatic\\.com\/static\/v\\d\/mip\\.css)|(c\\.mipcdn\\.com\/static\/v\\d\/mip\\.css))$/"
}],

"mandatory_parent": "head",
"duplicate": [{
"rel": "/^(miphtml)|(standardhtml)$/"
}, {
"rel": "/^(miphtml)|(canonical)$/"
}, {
"rel": "/^stylesheet$/",
"href": "/^(https:)?\/\/(mipcache.bdstatic.com\/static\/mipmain)|(m.baidu.com\/static\/ala\/sf\/static\/)|(c.mipcdn.com\/static\/mipmain)/"
"rel": "/^(canonical)|(standardhtml)$/"
}],
"attrs": {
"href": [{
"value": "/^(http(s)?:)?\/\//",
"match": {
"rel": "/^(miphtml)|(canonical)|(standardhtml)$/"
"rel": "/^(canonical)|(standardhtml)$/"
}
}, {
"value": "/^(?!\/[^\/])/",
"match": {
"rel": "/^(?!(miphtml)|(canonical)|(standardhtml))$/"
"rel": "/^(?!(canonical)|(standardhtml))$/"
}
}]

Expand All @@ -86,13 +80,12 @@
"script": [
{
"mandatory": {
"type": "/^(text\/javascript)?/",
"src": "/^(https:)?\/\/(mipcache.bdstatic.com\/static\/mipmain)|(m.baidu.com\/static\/ala\/sf\/static\/)|((https:)?\/\/mipcache.bdstatic.com\/static\/v\\d\/)|((https:)?\/\/c.mipcdn.com\/static\/v\\d\/)|((https:)?\/\/c.mipcdn.com\/static\/mipmain)/"
"src": "/^(https:)?\/\/((mipcache\\.bdstatic\\.com\/static\/mipmain-v\\d\\.\\d\\.\\d\\.js)|(c\\.mipcdn\\.com\/static\/mipmain-v\\d\\.\\d\\.\\d\\.js)|(mipcache\\.bdstatic\\.com\/static\/v\\d\/mip\\.js)|(c\\.mipcdn\\.com\/static\/v\\d\/mip\\.js))$/"
}
},
{
"match": {
"src": "/^(https:)?\/\/(mipcache.bdstatic.com\/static\/mipmain)|(m.baidu.com\/static\/ala\/sf\/static\/)|((https:)?\/\/mipcache.bdstatic.com\/static\/v\\d\/)|((https:)?\/\/c.mipcdn.com\/static\/v\\d\/)|((https:)?\/\/c.mipcdn.com\/static\/mipmain)/"
"src":"/^(https:)?\/\/((mipcache\\.bdstatic\\.com)|(c\\.mipcdn\\.com))/"
},
"attrs": {
"type": {
Expand All @@ -102,7 +95,7 @@
}, {
"match_ancestor": "head",
"match": {
"src":"/^((https:)?\/\/mipcache.bdstatic.com)|((https:)?\/\/m.baidu.com\/static\/ala\/sf\/static\/)|((https:)?\/\/c.mipcdn.com)/"
"src":"/^(https:)?\/\/((mipcache\\.bdstatic\\.com)|(c\\.mipcdn\\.com))/"
},
"attrs": {
"async": {
Expand All @@ -113,7 +106,7 @@
"disallow": true,
"match": {
"type": "/^(?!application\/(ld\\+)?json)/",
"src":"/^(?!((https:)?\/\/mipcache.bdstatic.com)|((https:)?\/\/m.baidu.com\/static\/ala\/sf\/static\/)|((https:)?\/\/c.mipcdn.com))/"
"src":"/^(?!((https:)?\/\/mipcache\\.bdstatic\\.com)|((https:)?\/\/c\\.mipcdn\\.com))/"
}
}, {
"disallowed_ancestor": "template"
Expand All @@ -126,9 +119,6 @@
}
}
},



"img": {
"disallow": true
},
Expand Down Expand Up @@ -282,7 +272,7 @@
"mip-form": {
"attrs": {
"method": {
"value": "/^(post)|(get)$/i"
"value": "/^((post)|(get))$/i"
},
"url": {
"mandatory": true,
Expand Down

0 comments on commit 40ac8eb

Please sign in to comment.