Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

std: remove wildcard export in uuid module #3540

Merged
merged 7 commits into from
Dec 23, 2019
Merged

std: remove wildcard export in uuid module #3540

merged 7 commits into from
Dec 23, 2019

Conversation

axetroy
Copy link
Contributor

@axetroy axetroy commented Dec 23, 2019

wildcard exports is a bad practice

export default function xxx() {
}

currently ✖️

import defaultGenerate, { v4 } from "https://deno.land/x/std/uuid/mod.ts" 
import generate from "https://deno.land/x/std/uuid/v4.ts" 

defaultGenerate();
generate();
v4();

Goal ☑️

import { v4 } from "https://deno.land/x/std/uuid/mod.ts" 
import { generate } from "https://deno.land/x/std/uuid/v4.ts" 

v4.generate();
generate();

@axetroy axetroy changed the title std: remove wildcard imports in uuid module std: remove wildcard export in uuid module Dec 23, 2019
std/uuid/mod.ts Outdated Show resolved Hide resolved
Copy link
Member

@kt3k kt3k left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I like the idea.

Copy link
Member

@ry ry left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@ry ry merged commit e88c801 into denoland:master Dec 23, 2019
@axetroy axetroy deleted the export_default branch December 23, 2019 09:41
bartlomieju pushed a commit to bartlomieju/deno that referenced this pull request Dec 28, 2019
caspervonb pushed a commit to caspervonb/deno_std that referenced this pull request Jan 21, 2021
caspervonb pushed a commit to caspervonb/deno_std that referenced this pull request Jan 24, 2021
caspervonb pushed a commit to caspervonb/deno_std that referenced this pull request Jan 24, 2021
caspervonb pushed a commit to caspervonb/deno_std that referenced this pull request Jan 24, 2021
caspervonb pushed a commit to caspervonb/deno_std that referenced this pull request Jan 31, 2021
caspervonb pushed a commit to caspervonb/deno_std that referenced this pull request Jan 31, 2021
caspervonb pushed a commit to caspervonb/deno_std that referenced this pull request Jan 31, 2021
caspervonb pushed a commit to caspervonb/deno_std that referenced this pull request Jan 31, 2021
caspervonb pushed a commit to caspervonb/deno_std that referenced this pull request Feb 1, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants