c3ff0d4c17
* Under jsx: preserve, actually preserve expressions which contain only comments * Even better best effort comment preservation in JSX comments
60 lines
798 B
TypeScript
60 lines
798 B
TypeScript
//// [file.tsx]
|
|
import React = require('react');
|
|
|
|
<div>
|
|
// Not Comment
|
|
</div>;
|
|
|
|
<div>
|
|
// Not Comment
|
|
{
|
|
//Comment just Fine
|
|
}
|
|
// Another not Comment
|
|
</div>;
|
|
|
|
<div>
|
|
// Not Comment
|
|
{
|
|
//Comment just Fine
|
|
"Hi"
|
|
}
|
|
// Another not Comment
|
|
</div>;
|
|
|
|
<div>
|
|
/* Not Comment */
|
|
{
|
|
//Comment just Fine
|
|
"Hi"
|
|
}
|
|
</div>;
|
|
|
|
//// [file.jsx]
|
|
"use strict";
|
|
exports.__esModule = true;
|
|
var React = require("react");
|
|
<div>
|
|
// Not Comment
|
|
</div>;
|
|
<div>
|
|
// Not Comment
|
|
{
|
|
//Comment just Fine
|
|
}
|
|
// Another not Comment
|
|
</div>;
|
|
<div>
|
|
// Not Comment
|
|
{
|
|
//Comment just Fine
|
|
"Hi"}
|
|
// Another not Comment
|
|
</div>;
|
|
<div>
|
|
/* Not Comment */
|
|
{
|
|
//Comment just Fine
|
|
"Hi"}
|
|
</div>;
|