1
我主要開發內部網絡應用程序,其中IE8仍安裝在許多PC上作爲主要Web瀏覽器。我想要包含此HTML5佔位符plolyfill,https://github.com/ginader/HTML5-placeholder-polyfill,適用於我所有基於Durandal的視圖。什麼是實現這一目標的最佳方式?Durandal風格視圖應該在哪裏包含polyfill?
我主要開發內部網絡應用程序,其中IE8仍安裝在許多PC上作爲主要Web瀏覽器。我想要包含此HTML5佔位符plolyfill,https://github.com/ginader/HTML5-placeholder-polyfill,適用於我所有基於Durandal的視圖。什麼是實現這一目標的最佳方式?Durandal風格視圖應該在哪裏包含polyfill?
除了根據說明書將polyfill加載到SPA以外,沒有特別的考慮。當然,因爲這個polyfill需要jQuery,所以確保jQuery在包含它之前加載。
例如
<head>
....
<link rel="stylesheet" href="placeholder_polyfill.min.css">
...
<script src="placeholder_polyfill.jquery.min.combo.js" charset="utf-8"></script>
...
</head>