Add mitt doc
parent
0befe4ebe8
commit
ac7ee76682
|
@ -52,12 +52,10 @@
|
|||
"primeicons": "4.0.0",
|
||||
"prismjs": "^1.15.0",
|
||||
"quill": "1.3.3",
|
||||
"mitt": "^2.1.0",
|
||||
"@fullcalendar/core": "4.0.2",
|
||||
"@fullcalendar/daygrid": "4.0.1",
|
||||
"@fullcalendar/interaction": "4.0.2",
|
||||
"@fullcalendar/timegrid": "4.0.1"
|
||||
},
|
||||
"dependencies": {
|
||||
"mitt": "^2.1.0"
|
||||
}
|
||||
}
|
||||
|
|
|
@ -97,6 +97,10 @@ dependencies: {
|
|||
<td>PrimeFlex</td>
|
||||
<td>DataView</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Mitt</td>
|
||||
<td>Toast and Terminal</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
|
|
|
@ -2,6 +2,12 @@
|
|||
<div class="content-section documentation">
|
||||
<TabView>
|
||||
<TabPanel header="Documentation">
|
||||
<h5>Mitt EventBus</h5>
|
||||
<p>Terminal requires <a href="https://www.npmjs.com/package/mitt">Mitt</a>, a tiny 200b EventBus implementation.</p>
|
||||
<CodeHighlight>
|
||||
npm install mitt --save
|
||||
</CodeHighlight>
|
||||
|
||||
<h5>Import</h5>
|
||||
<CodeHighlight lang="javascript">
|
||||
import Terminal from 'primevue/terminal';
|
||||
|
@ -120,7 +126,7 @@ export default {
|
|||
</div>
|
||||
|
||||
<h5>Dependencies</h5>
|
||||
<p>None.</p>
|
||||
<p>Mitt.</p>
|
||||
</TabPanel>
|
||||
|
||||
<TabPanel header="Source">
|
||||
|
|
|
@ -2,18 +2,21 @@
|
|||
<div class="content-section documentation">
|
||||
<TabView>
|
||||
<TabPanel header="Documentation">
|
||||
<h5>Mitt EventBus</h5>
|
||||
<p>Toast requires <a href="https://www.npmjs.com/package/mitt">Mitt</a>, a tiny 200b EventBus implementation.</p>
|
||||
<CodeHighlight>
|
||||
npm install mitt --save
|
||||
</CodeHighlight>
|
||||
|
||||
<h5>ToastService</h5>
|
||||
<p>Toast messages are dynamically created using a <i>ToastService</i> that needs to be installed globally before the application
|
||||
instance is created.</p>
|
||||
<CodeHighlight lang="javascript">
|
||||
import {createApp} from 'vue';
|
||||
import ToastService from 'primevue/toastservice';
|
||||
Vue.use(ToastService);
|
||||
|
||||
//example application instance
|
||||
new Vue({
|
||||
router,
|
||||
render: h => h(App)
|
||||
}).$mount('#app');
|
||||
const app = createApp(App);
|
||||
app.use(ToastService);
|
||||
</CodeHighlight>
|
||||
|
||||
<h5>Import</h5>
|
||||
|
@ -21,6 +24,7 @@ new Vue({
|
|||
import Toast from 'primevue/toast';
|
||||
</CodeHighlight>
|
||||
|
||||
|
||||
<h5>Getting Started</h5>
|
||||
<p>Ideal location of a Toast is the main application template so that it can be used by any component within the application.</p>
|
||||
|
||||
|
@ -243,7 +247,7 @@ this.$toast.removeAllGroups();
|
|||
</div>
|
||||
|
||||
<h5>Dependencies</h5>
|
||||
<p>None.</p>
|
||||
<p>Mitt.</p>
|
||||
</TabPanel>
|
||||
|
||||
<TabPanel header="Source">
|
||||
|
|
Loading…
Reference in New Issue