Created tags list page

This commit is contained in:
Alejandro Celaya
2018-08-16 18:59:00 +02:00
parent 03113583f0
commit 49290b56ee
12 changed files with 150 additions and 8 deletions

View File

@@ -49,6 +49,11 @@ export class ShlinkApiClient {
.then(resp => resp.data.tags)
.catch(e => this._handleAuthError(e, this.updateShortUrlTags, [shortCode, tags]));
listTags = () =>
this._performRequest('/tags', 'GET')
.then(resp => resp.data.tags.data)
.catch(e => this._handleAuthError(e, this.listTags, []));
_performRequest = async (url, method = 'GET', params = {}, data = {}) => {
if (isEmpty(this._token)) {
this._token = await this._authenticate();