Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

<noscript> 标签验证优化 #28

Open
xuexb opened this issue Mar 17, 2018 · 2 comments
Open

<noscript> 标签验证优化 #28

xuexb opened this issue Mar 17, 2018 · 2 comments

Comments

@xuexb
Copy link
Contributor

xuexb commented Mar 17, 2018

  1. <noscript> 标签重复性未验证
  2. <noscript> 标签内部元素未验证

以下代码验证通过:

<!DOCTYPE html>
<html mip>
    <head>
        <meta charset="UTF-8">
        <meta name="viewport" content="width=device-width,minimum-scale=1,initial-scale=1">
        <link rel="stylesheet" type="text/css" href="https://c.mipcdn.com/static/v1/mip.css">
        <!--TODO: canonical href需要替换成原页面url-->
        <link rel="canonical" href="https://www.mipengine.org/test_xxx.html">
        <title>MIP页Demo效果</title>
        <!--noscript 用于JS禁用时页面加载-->
        <noscript>
            <style mip-officialrelease>
                body {
                    -webkit-animation: none;
                    -moz-animation: none;
                    -ms-animation: none;
                    animation: none
                }
            </style>
            <style>
                body {}
            </style>
        </noscript>
    </head>
    <body>
        <!--noscript 用于JS禁用时页面加载-->
        <noscript>
            <style mip-officialrelease>
                body {
                    -webkit-animation: none;
                    -moz-animation: none;
                    -ms-animation: none;
                    animation: none
                }
            </style>
            <style>
                body {}
            </style>
        </noscript>
        <!--mip 运行环境-->
        <script src="https://c.mipcdn.com/static/v1/mip.js"></script>
    </body>
</html>

image

@xuexb
Copy link
Contributor Author

xuexb commented Mar 17, 2018

并且需要明确下:

  1. 内部元素是不是只能是 <style mip-officialrelease>
  2. 如果用户有在禁用脚本时发送一个 *.gif 日志需要如何处理?

@harttle
Copy link
Member

harttle commented Mar 19, 2018

如果需求一样的话,<noscript> 可以类似 <template> 那样处理

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants