mirror of
https://github.com/coderaiser/cloudcmd.git
synced 2026-01-23 10:45:47 +00:00
feature(index) speed up event: load -> DOMContentLoaded
This commit is contained in:
parent
764dcf8464
commit
f0eb586e38
1 changed files with 3 additions and 3 deletions
|
|
@ -32,18 +32,18 @@
|
|||
<button id=~ class="cmd-button reduce-text icon-console" title="console" >~</button>
|
||||
<button id=contact class="cmd-button reduce-text icon-contact" title="contact" ></button>
|
||||
</div>
|
||||
<script src="/cloudcmd/cloudcmd.js"></script>
|
||||
<script>
|
||||
!(function() {
|
||||
'use strict';
|
||||
|
||||
window.addEventListener('load', load);
|
||||
window.addEventListener('DOMContentLoaded', load);
|
||||
|
||||
function load() {
|
||||
window.removeEventListener('load', load);
|
||||
window.removeEventListener('DOMContentLoaded', load);
|
||||
CloudCmd();
|
||||
}
|
||||
})();
|
||||
</script>
|
||||
<script src="/cloudcmd/cloudcmd.js"></script>
|
||||
</body>
|
||||
</html>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue