-
Notifications
You must be signed in to change notification settings - Fork 103
Traduction de plugins.md
#69
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
Conversation
Signed-off-by: Bruno Lesieur <[email protected]>
Signed-off-by: Bruno Lesieur <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Quelques petites fautes, gj
src/v2/guide/plugins.md
Outdated
|
||
``` js | ||
// calls `MyPlugin.install(Vue)` | ||
// appeler `MyPlugin.install(Vue)` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
appelle
src/v2/guide/plugins.md
Outdated
|
||
Some plugins provided by Vue.js official plugins such as `vue-router` automatically calls `Vue.use()` if `Vue` is available as a global variable. However in a module environment such as CommonJS, you always need to call `Vue.use()` explicitly: | ||
Plusieurs plugins fournient officiellement par Vue.js comme `vue-router` appel `Vue.use()` si `Vue` est disponible en tant que variable globale. Cependant, dans un environnement par module comme avec CommonJS, vous devrez toujours manuellement appeler `Vue.use()` : |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
fournis
appelle
Signed-off-by: Bruno Lesieur <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Quelques remarques et propositions
src/v2/guide/plugins.md
Outdated
|
||
<p class="tip">**Cette page est en cours de traduction française. Revenez une autre fois pour lire une traduction achevée ou [participez à la traduction française ici](https://github.com/vuejs-fr/vuejs.org).**</p><p>Plugins usually add global-level functionality to Vue. There is no strictly defined scope for a plugin - there are typically several types of plugins you can write:</p> | ||
Les plugins sont habituellement ajoutés au niveau des fonctionnalités globales de Vue. Il y a un cadre strictement défini pour un plugin, et il y a divers types de plugins que vous pouvez écrire pour : |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
pour un plugin et il y a divers types de plugins que vous pouvez écrire pour :
Enlever la virgule après plugin, normalement, le mot et n'est pas précédé d'une virgule
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Tout à fait
src/v2/guide/plugins.md
Outdated
|
||
2. Add one or more global assets: directives/filters/transitions etc. e.g. [vue-touch](https://github.com/vuejs/vue-touch) | ||
2. Ajouter une ou plusieurs fonctionnalités : directives/filters/transitions, etc. Par ex. [vue-touch](https://github.com/vuejs/vue-touch) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
directives, filtres, transitions, etc.
Séparer par des virgules et traduction de filters en filtres
src/v2/guide/plugins.md
Outdated
|
||
4. Add some Vue instance methods by attaching them to Vue.prototype. | ||
4. Ajouter plusieurs méthodes d'instance de Vue attachées au prototype de Vue. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ajouter plusieurs des méthodes d'instance de Vue attachées en les reliant au prototype de Vue.
src/v2/guide/plugins.md
Outdated
|
||
5. A library that provides an API of its own, while at the same time injecting some combination of the above. e.g. [vue-router](https://github.com/vuejs/vue-router) | ||
5. Fournir une bibliothèque avec sa propre API, qui injecte en même temps certains des éléments précédemment cités. Par ex. [vue-router](https://github.com/vuejs/vue-router) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
certains des éléments précédemment cités
src/v2/guide/plugins.md
Outdated
|
||
A Vue.js plugin should expose an `install` method. The method will be called with the `Vue` constructor as the first argument, along with possible options: | ||
Un plugin Vue.js doit exposer une méthode `install`. Cette méthode va être appelée avec le constructeur de `Vue` en tant que premier argument, avec les options possibles suivantes : |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Cette méthode sera va être appelée
src/v2/guide/plugins.md
Outdated
} | ||
|
||
// 2. add a global asset | ||
// 2. ajouter des fonctionnalités |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ajouter une ressource global des fonctionnalités
ressource me parait une meilleure traduction
src/v2/guide/plugins.md
Outdated
} | ||
... | ||
}) | ||
|
||
// 4. add an instance method | ||
// 4. ajouter des méthodes d'instance |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ajouter des méthodes une méthode d'instance
src/v2/guide/plugins.md
Outdated
|
||
``` js | ||
Vue.use(MyPlugin, { someOption: true }) | ||
``` | ||
|
||
`Vue.use` automatically prevents you from using the same plugin more than once, so calling it multiple times on the same plugin will install the plugin only once. | ||
`Vue.use` va automatiquement vous empécher d'utiliser plusieurs fois le même plugin, ainsi appeler de multiple fois le même plugin ne l'installera qu'une fois. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Vue.use
va empêchera automatiquement vous empécher d'utiliser plusieurs fois le même plugin
src/v2/guide/plugins.md
Outdated
|
||
Some plugins provided by Vue.js official plugins such as `vue-router` automatically calls `Vue.use()` if `Vue` is available as a global variable. However in a module environment such as CommonJS, you always need to call `Vue.use()` explicitly: | ||
Certains plugins fournis officiellement par Vue.js comme `vue-router` appelle `Vue.use()` si `Vue` est disponible en tant que variable globale. Cependant, dans un environnement par module comme avec CommonJS, vous devrez toujours manuellement appeler `Vue.use()` : |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
comme vue-router
appelle automatiquement Vue.use()
il manque le mot automatiquement
environnement par module comme avec CommonJS
proposition : environnement modulaire comme CommonJS
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Bon pour moi
Signed-off-by: Bruno Lesieur <[email protected]>
Merci @forresst pour tes retours !! C'est pris en compte :) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
relecture en retard
|
||
2. Add one or more global assets: directives/filters/transitions etc. e.g. [vue-touch](https://github.com/vuejs/vue-touch) | ||
2. Ajouter une ou plusieurs ressource global : directives, filters, transitions, etc. Par ex. [vue-touch](https://github.com/vuejs/vue-touch) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ressources globales
|
||
5. A library that provides an API of its own, while at the same time injecting some combination of the above. e.g. [vue-router](https://github.com/vuejs/vue-router) | ||
5. Fournir une bibliothèque avec sa propre API, qui injecte en même temps certains éléments précédemment cités. Par ex. [vue-router](https://github.com/vuejs/vue-router) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Une bibliothèque qui fournit sa propre API, et qui en même temps injecte une combinaison des points précédents.
} | ||
|
||
// 2. add a global asset | ||
// 2. ajouter une ressource global |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
globale
|
||
Use plugins by calling the `Vue.use()` global method: | ||
Utiliser un plugin en appelant la méthode globale `Vue.use()` : |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Une fois n'est pas coutume, l'usage de l'infinitif fait de toutes ces phrases des phrases nominales, ce qui selon moi est en rupture avec le reste du guide. Je préfère largement l'usage de l'impératif, mais je pense qu'on aura du mal à se mettre d'accord
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
J'y songe, j'y songe. Je médite, je médite. Naturellement j'utilise l'impératif alors pour le moment je reste consistant avec moi-même. Il me faudrait un chantier dédié (PR) pour bien cerner les nuances j'imagine. J'en ai également déjà parlé mais c'est pas ma priorité. Je m'inspirerais de l'API p-e car je pense bien que tu utilises l'infinitif.
|
||
``` js | ||
// calls `MyPlugin.install(Vue)` | ||
// appel `MyPlugin.install(Vue)` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
appelle
|
||
``` js | ||
Vue.use(MyPlugin, { someOption: true }) | ||
``` | ||
|
||
`Vue.use` automatically prevents you from using the same plugin more than once, so calling it multiple times on the same plugin will install the plugin only once. | ||
`Vue.use` empêchera automatiquement l'utilisation du même plugin plusieurs fois. Ainsi appeler de multiple fois le même plugin ne l'installera qu'une fois. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
(virgule après Ainsi : http://www.langue-fr.net/Aussi-Ainsi-difference-et-construction)
appeler cette fonction plusieurs fois sur le même plugin n'installera le plugin qu'une seule fois
|
||
Some plugins provided by Vue.js official plugins such as `vue-router` automatically calls `Vue.use()` if `Vue` is available as a global variable. However in a module environment such as CommonJS, you always need to call `Vue.use()` explicitly: | ||
Certains plugins fournis officiellement par Vue.js comme `vue-router` appelle automatiquement `Vue.use()` si `Vue` est disponible en tant que variable globale. Cependant, dans un environnement modulaire comme avec CommonJS, vous devrez toujours manuellement appeler `Vue.use()` : |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
appellent
explicitly => explicitement
Vue.use(VueRouter) | ||
``` | ||
|
||
Checkout [awesome-vue](https://github.com/vuejs/awesome-vue#components--libraries) for a huge collection of community-contributed plugins and libraries. | ||
Consultez [awesome-vue](https://github.com/vuejs/awesome-vue#components--libraries) pour une large collection de plugin et bibliothèque fournis par la contribution de la communauté. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
plugins et bibliothèques
Merci @sylvainpolletvillard pour tes retours. C'est dans la boîte ré-troactivement sur le prochain commit. |
Et une petite page en plus.