Skip to main content

Changelog: swc v1.2.91

· One min read

To see full list of patches, please visit https://github.com/swc-project/swc/milestone/192?closed=1

Bugfixes#

hygiene (#2297)#

There was an edge case I missed.

Fixed (again) by #2299.

parser: JSX (#2264)#

Previously swc sometimes collect the jsx text below as comments.

const t = <Switch>// 1 /* 2 */</Switch>;

Fixed by #2255.

parser: Function in tsx (#2237)#

Previously the parser of swc failed to parse the input below.

import React from "react";
export function Results() {  return (    <div>      {[].map(() => {        function onClick(): void {}
        return null;      })}    </div>  );}

Fixed by #2255.

sourceMap: true in .swcrc (#2194)#

Fixed by #2292.