We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 8ab3b0a commit 35a12b6Copy full SHA for 35a12b6
1 file changed
docs/module.md
@@ -149,11 +149,25 @@ export {n as m};
149
150
同样的,`function`和`class`的输出,也必须遵守这样的写法。
151
152
+NOTE: 测试 https://babeljs.io/repl/
153
+
154
```javascript
155
// 报错
156
function f() {}
157
export f;
158
159
+// 正确
160
+function f() {}
161
+export default f;
162
163
+// 报错
164
+var f = function f() {}
165
+export f;
166
167
168
+const f = function func() {}
169
170
171
// 正确
172
export function f() {};
173
@@ -776,4 +790,3 @@ async function main() {
776
790
}
777
791
main();
778
792
```
779
-
0 commit comments