arty-name / martian-cidr

Check if an IP address is from reserved subnet
MIT License
2 stars 1 forks source link

Name of package is non obvious #50

Closed toplenboren closed 3 months ago

toplenboren commented 3 months ago

Hi! Thanks for your work!

Really like your package :-) but I think the name isMartian is not really obvious.. You have to explain what a martian packet is every time you use it..

I think calling library isReservedIp(ip) might be more obvious for end user

What do you think?

arty-name commented 3 months ago

Thank you for your kind words!

Since the package doesn’t use named export, you can use any name you like for the imported function.

import isMartianIP from 'martian-cidr'; // suggested in the readme
import isReservedIp from 'martian-cidr'; // feel free to import it like this instead

Would that work for you?

toplenboren commented 3 months ago

Yep, this might work for me :-) thanks for the prompt response!

arty-name commented 3 months ago

Sweet! I’ll mark it as resolved then.