Coder Social home page Coder Social logo

vi-vue-utils's Introduction

A hexagonal logo of the viur-cli

ViUR Vue Utils

Badge showing current NPM version Badge displaying the license
A library for communication with the ViUR Core

What does it do?

ViUR Vue Utils is a library to work with the Viur Framework

Installation

$ npm i @viur/vue-utils

Usage

import {Request, ListRequest, destroyStore} from '@viur/vue-utils'

const simpleRequest = ref() //reactive variable
Request.get("https://jsonplaceholder.typicode.com/todos/1").then(async (resp: Response)=>{
    simpleRequest.value = await resp.json() //decode and set reactive variable
})


let userList = ListRequest(
    "teststore", // unqiue name of the Pinia store
    {url:"/user/list", params:{"limit":10}}
)

//fetches all users
userList.fetchAll().catch((e)=>{
    console.log(e)
    console.log(e.statusCode)
    console.log(e.statusText)
    console.log(e.response)
})

// if the results and the request is not needed anymore
destroyStore(userList)

Dependencies

ViUR Vue Utils depends on

License

Copyright © 2023 by Mausbrand Informationssysteme GmbH.
Mausbrand and ViUR are registered trademarks of Mausbrand Informationssysteme GmbH.

This project is free software under the MIT license.
Please see the LICENSE file for details.

vi-vue-utils's People

Contributors

akelch avatar claudiadietrichlev avatar timmytiefkuehl avatar arnegudermann avatar kadirbalku avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.