Hacker News new | past | comments | ask | show | jobs | submit login

To those who say that creating a JavaScript 2.0 would break compatibility... couldn't you have a .js2 extension and compile a .js as a fallback. The newer browser would ignore the fallback and use the js2. Thoughts??

Example: <!-- JavaScript 2.0, unsupported browsers ignore --> <script src="main.js2" fallback="main.js"></script> <!-- Fallback compiled to current JavaScript --> <script src="main.js"></script>




Consider applying for YC's W25 batch! Applications are open till Nov 12.

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: