fastcomments-vue
    TypeScript icon, indicating that this package has built-in type declarations

    2.1.0 • Public • Published

    fastcomments-vue

    A Vue library for FastComments, a fast and developer friendly comment system.

    NPM JavaScript Style Guide

    For Vue 3.0, see fastcomments-vue-next.

    Installation

    NPM

    npm install --save fastcomments-vue

    Yarn

    yarn add fastcomments-vue

    Usage

    The Comment Widget

    The FastCommentsVue component contains the live FastComments comment widget.

    Replace "demo" below with your "tenantId" - available here in the FastComments admin area.

    The widget supports a lot of options - see FastCommentsConfig here.

    <script lang="ts">
    import Vue from 'vue';
    import FastCommentsVue from 'fastcomments-vue';
    
    export default Vue.extend({
      name: 'ServeDev',
      components: {
        FastCommentsVue
      }
    });
    </script>
    
    <template>
      <div id="app">
        <fast-comments-vue v-bind:config="{tenantId: 'demo'}" />
      </div>
    </template>

    Updating The Current Page (SPA Example)

    In FastComments we call the article id, or page the comments get tied to, the URL ID as it can be a url or an ID. Define the URL ID in the following manner. The component watches for changes in config object, and will reload, so you can just update the "url" and "urlId" settings.

    See a full working example here.

    Run the pagination example via:

    npm run serve-pagination
    
    <fast-comments-vue v-bind:config="{tenantId: 'demo', url: 'https://example.com', urlId: 'some-page-id'}" />

    Contributing

    Please checkout our contribution guidelines before starting on a change. Remember to communicate first!

    License

    MIT © winrid

    Keywords

    none

    Install

    npm i fastcomments-vue

    DownloadsWeekly Downloads

    1

    Version

    2.1.0

    License

    MIT

    Unpacked Size

    55.2 kB

    Total Files

    11

    Last publish

    Collaborators

    • winrid-org