Closed f closed 6 years ago
vue-loading
sounds good for me
It's occupied on npm.
vuel
as have made vuex
or to leave a project name as is if there is no option better
What about vue-wait
?
I decided not to change it for now, if a brilliant idea comes, we can think about it. Also, renaming would cause some problems in future.
I asked npm if they can give me the name vuel and they did. I published the repo with vuel
name, but I also liked vue-wait
. On the other hand, vuel sounds more brand-ish.
I'm not sure but for next major version, maybe we can rename it too. Or maybe renaming a project twice is not a really good idea :)
However, we now have vuel
name.
vuel
more brand-ish and more fancier (hipster) name, i don't think renaming project twice is a problem if renaming has occurred within a week.
But what to do with other names?
rename VueWait
to ?
rename $wait
to ?
isWaiting
become isLoading
?
VueWait
-> Vuel
$wait
-> $vuel
For isWaiting
or isLoading
what about just is
since we already using $vuel
prefix?
$vuel.is("creating users")
sounds legit to me.
And we should think about slot
name waiting
. I think we should only rename VueWait
to Vuel
and let's leave rest as is.
@f agree.
slot waiting
can be renamed to loading
also method is
need some more explicit name
What about is
to waits
.
$vuel.waits('creating user') => Boolean
$vuel.waits('cart.*') => Boolean
In view isLoading
or isWaiting
feels so long to me. I feel like I write isLoading
everywhere and code becomes too ugly. I'm trying to make it shorter. And as you said is
also too short and implicit.
I wish we can use ?
as method name just like in Ruby so we could use waits?('create.*)
.
This is the latest API proposal, let's discuss on it:
$vuel.start('creating user') # Starts a loader
$vuel.end('creating user') # Ends a loader
$vuel.waits('creating user') # Individual loading exists
$vuel.any # Any loading exists
# Template
<vuel for='creating user'>
<template slot='loading'>Loading...</template>
</vuel>
# Mappers
...mapVuelGetters({...})
...mapVuelActions('module', {...})
Current Keyword | Proposal |
---|---|
$wait |
$vuel |
start |
start |
end |
end |
is |
waits |
any |
any |
wait (store name) |
vuel |
<v-wait> |
<vuel> |
for="" |
for="" |
slot="waiting" |
slot="loading" |
mapWaitingGetters |
mapVuelGetters |
mapWaitingActions |
mapVuelActions |
Please share your own proposals.
is
- isActive
any
- anyActive
maybe slot="loading"
- slot="active"
for consistency
not sure <vuel>
is a good name (no prefix)
Maybe @Koc also can share his opinions about it.
or without is
prefix
is
- active
any
- activeAny
- or change semantic to check any
if no args passed and remove this methodYep this is better. Removing things feel me better :)
What about <vuel>
? What about <vuel-wait for="creating users">
? Since wait for doing something
is a legit English sentence, <vuel-wait for="creating users">
sounds good to me.
<vuel-wait for="creating user">
<template slot="active">Creating user, please wait...</template>
User created.
</vuel-wait>
If we make <vuel-wait>
or <vuel-X>
, we should make slot name consistent to X.
<vuel-wait for="creating user">
<template slot="waiting">Creating user, please wait...</template>
User created.
</vuel-wait>
I'm prefer leave $wait
is it possible and rename is
to waiting
: $wait.waiting('product')
Since
vuex-loading
is not really Vuex related now, we need a new name.vue-loading
is registered.Maybe we can find a fancier (hipster) name. Should we use
vue-
prefix?