1.40.1 • Published 10 months ago

@uportal/api-template-vue v1.40.1

Weekly downloads
-
License
-
Repository
github
Last release
10 months ago

api-template-vue

NPM Version Maven Central Build Status

Installation

# install with npm
npm install @uportal/api-template-vue

# install with yarn
yarn add @uportal/api-template-vue

install with maven

<dependency>
    <groupId>org.webjars.npm</groupId>
    <artifactId>uportal__api-template-vue</artifactId>
    <version>{version number goes here}</version>
</dependency>

install with gradle

compile 'org.webjars.npm:uportal__api-template-vue:{version number goes here}'

Usage as Web Component

The component requires a data-api-url (URL to acquire a JSON payload).

<script src="https://unpkg.com/vue"></script>
<script src="https://unpkg.com/@uportal/api-template-vue"></script>

<api-template-vue data-api-url="/uPortal/api/v5-0/people/me">
  <div class="card">
    <div class="card-body">
      <h3 class="card-title">{{ data.displayName[0] }}</h3>
      <table class="table">
        <caption>
          User attributes
        </caption>
        <tbody>
          <tr>
            <td>username:</td>
            <td>{{ data.username[0] }}</td>
          </tr>
          <tr>
            <td>email:</td>
            <td>{{ data.mail[0] }}</td>
          </tr>
          <tr>
            <td>Phone:</td>
            <td>{{ data.telephoneNumber[0] }}</td>
          </tr>
        </tbody>
      </table>
    </div>
  </div>
</api-template-vue>

Options

  • data-api-url (required, string): URL of the REST API that provides JSON data to the template.

Slot Content

The default slot defines the Vue-based template containing the markup that will appear on the page.

1.40.0

10 months ago

1.40.1

10 months ago

1.39.0

11 months ago

1.38.1

1 year ago

1.37.0

3 years ago

1.36.0

4 years ago

1.35.0

4 years ago

1.34.3

4 years ago

1.34.2

4 years ago

1.34.1

4 years ago

1.34.0

4 years ago

1.33.2

5 years ago

1.33.1

5 years ago

1.33.0

5 years ago

1.32.1

5 years ago

1.32.0

5 years ago

1.31.1

5 years ago

1.31.0

5 years ago

1.30.1

5 years ago

1.30.0

5 years ago

1.29.0

5 years ago

1.28.0

5 years ago

1.27.0

5 years ago

1.26.2

5 years ago

1.26.1

5 years ago

1.26.0

5 years ago

1.25.0

5 years ago

1.24.0

5 years ago

1.23.0

5 years ago

1.22.1

5 years ago

1.22.0

5 years ago