Skip to content

Commit c57bc5a

Browse files
authoredJan 4, 2021
fix: change default export to named function (#545)
Frameworks like Next.js complain about anonymous export default functions, e.g. `Anonymous function declarations cause Fast Refresh to not preserve local component state.` Versions except for v3/5 already use named exports, so update v3/5 to do the same.
1 parent ed32401 commit c57bc5a

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed
 

‎src/v35.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ function stringToBytes(str) {
1616
export const DNS = '6ba7b810-9dad-11d1-80b4-00c04fd430c8';
1717
export const URL = '6ba7b811-9dad-11d1-80b4-00c04fd430c8';
1818

19-
export default function (name, version, hashfunc) {
19+
export default function v35(name, version, hashfunc) {
2020
function generateUUID(value, namespace, buf, offset) {
2121
if (typeof value === 'string') {
2222
value = stringToBytes(value);

0 commit comments

Comments
 (0)
Please sign in to comment.