f / vue-wait

Complex Loader and Progress Management for Vue/Vuex and Nuxt Applications
MIT License
2k stars 100 forks source link

Renaming the repo #33

Closed f closed 6 years ago

f commented 6 years ago

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?

sky-code commented 6 years ago

vue-loading sounds good for me

f commented 6 years ago

It's occupied on npm.

sky-code commented 6 years ago

vuel as have made vuex or to leave a project name as is if there is no option better

f commented 6 years ago

What about vue-wait?

f commented 6 years ago

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.

f commented 6 years ago

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.

sky-code commented 6 years ago

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 ?

f commented 6 years ago

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.

f commented 6 years ago

And we should think about slot name waiting. I think we should only rename VueWait to Vuel and let's leave rest as is.

sky-code commented 6 years ago

@f agree. slot waiting can be renamed to loading also method is need some more explicit name

f commented 6 years ago

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.*).

f commented 6 years ago

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.

sky-code commented 6 years ago

maybe slot="loading" - slot="active" for consistency not sure <vuel> is a good name (no prefix)

f commented 6 years ago

Maybe @Koc also can share his opinions about it.

sky-code commented 6 years ago

or without is prefix

f commented 6 years ago

Yep 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>
f commented 6 years ago

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>
Koc commented 6 years ago

I'm prefer leave $wait is it possible and rename is to waiting: $wait.waiting('product')