22 lines
644 B
TypeScript
22 lines
644 B
TypeScript
//@filename: file.tsx
|
|
//@jsx: react
|
|
declare module JSX {
|
|
interface Element { }
|
|
interface IntrinsicElements {
|
|
[s: string]: any;
|
|
}
|
|
}
|
|
declare var React: any;
|
|
|
|
<div>Dot goes here: · ¬AnEntity; </div>;
|
|
<div>Be careful of "-ed strings!</div>;
|
|
<div>{{braces}}</div>;
|
|
// Escapes do nothing
|
|
<div>\n</div>;
|
|
|
|
// Also works in string literal attributes
|
|
<div attr="{…}\"></div>;
|
|
// Does not happen for a string literal that happens to be inside an attribute (and escapes then work)
|
|
<div attr={"{…}\""}></div>;
|
|
// Preserves single quotes
|
|
<div attr='"'></div>
|