<script>, <style> is PCDATA in XHTML

There is an issue in HTML parser. Fixed in XHTML.

Try it yourself:

Instantiated from outerHTML:

What you save is what you load.