Open-Source API Development Ecosystem • https://hoppscotch.io • Offline, On-Prem & Cloud • Web, Desktop & CLI • Open-Source Alternative to Postman, Insomnia
TypeScript apiapi-clientapi-restapi-testingdeveloper-toolsgraphqlhttphttp-clientpwarestrest-apispatestingtesting-toolstoolsvuevuejswebsocket
:pencil2: Meta
liyasthomasb561f6c8ae45
diff --git a/README.md b/README.mdindex 20c7227ee..bce352be5 100644--- a/README.md+++ b/README.md@@ -31,7 +31,6 @@ When I wrote this, only God and I understood what I was doing. Now, only God kno<div align="center"><br><img src="static/screenshot1.png" alt="postwoman" width="100%">- <img src="static/screenshot2.png" alt="postwoman" width="100%"><br></div>@@ -98,7 +97,7 @@ _Customized themes are also synced with local session storage_:page_with_curl: **Request Body**: Used to send and receive data via the REST API**Options:**- - Set content Type+ - Set Content Type- Toggle between RAW input and parameter list:wave: **Responses**: Contains the status line, headers and the message/response body@@ -184,7 +183,7 @@ Please read [CONTRIBUTING](CONTRIBUTING.md) for details on our [CODE OF CONDUCT]We use [Travis CI](https://travis-ci.com) for continuous integration. Check out our [Travis CI Status](https://travis-ci.com/liyasthomas/postwoman).-## Versioning ✅+## Versioning 🔖This project is developed by [Liyas Thomas](https://github.com/liyasthomas) using the [Semantic Versioning specification](https://semver.org). For the versions available, see the [releases on this repository](https://github.com/liyasthomas/postwoman/releases).@@ -194,15 +193,15 @@ See the [CHANGELOG](CHANGELOG.md) file for details.## Authors 🔮-### Lead Developers 👨💻+### Lead Developers* **[Liyas Thomas](https://github.com/liyasthomas)** - *Author*-### Testing and Debugging 🚧+### Testing and Debugging* ([contributors](https://github.com/liyasthomas/postwoman/graphs/contributors))-### Collaborators 🚸+### Collaborators<table><tr>@@ -221,11 +220,11 @@ See the [CHANGELOG](CHANGELOG.md) file for details.See the list of [contributors](https://github.com/liyasthomas/postwoman/graphs/contributors) who participated in this project.-### Thanks 🤝+### Thanks-* [Dribbble](https://dribbble.com)+* [dev.to](https://dev.to)-## Contributors 🍰+## Contributors 🚸### Code Contributorsdiff --git a/components/history.vue b/components/history.vueindex 7c48f06e3..88ebf3bb3 100644--- a/components/history.vue+++ b/components/history.vue@@ -53,7 +53,12 @@<label>Nothing found for "{{filterText}}"</label></li></ul>- <ul>+ <ul v-if="history.length === 0">+ <li>+ <label>History is empty</label>+ </li>+ </ul>+ <ul v-if="history.length !== 0"><li v-if="!isClearingHistory"><button class="icon" id="clear-history-button" :disabled="history.length === 0" @click="enableHistoryClearing"><i class="material-icons">clear_all</i>@@ -121,9 +126,7 @@this.disableHistoryClearing();updateOnLocalStorage('history', this.history);this.$toast.error('History Deleted', {- icon: 'delete',- position: 'bottom-center',- duration: 1000,+ icon: 'delete'});},useHistory(entry) {@@ -142,9 +145,7 @@}updateOnLocalStorage('history', this.history);this.$toast.error('Deleted', {- icon: 'delete',- position: 'bottom-center',- duration: 1000,+ icon: 'delete'});},addEntry(entry) {diff --git a/nuxt.config.js b/nuxt.config.jsindex d0d196fe7..2fd11ffea 100644--- a/nuxt.config.js+++ b/nuxt.config.js@@ -236,8 +236,17 @@ export default {}}],['@nuxtjs/axios'],- ['@nuxtjs/toast']+ ['@nuxtjs/toast'],+ ['@nuxtjs/google-analytics']],+ toast: {+ position: 'bottom-center',+ duration: 2000,+ theme: 'bubble'+ },+ googleAnalytics: {+ id: 'UA-61422507-2'+ },/*** Build configuration*/diff --git a/package-lock.json b/package-lock.jsonindex d46618d7d..830758cd4 100644--- a/package-lock.json+++ b/package-lock.json@@ -1252,6 +1252,14 @@"consola": "^2.10.1"}},+ "@nuxtjs/google-analytics": {+ "version": "2.2.0",+ "resolved": "https://registry.npmjs.org/@nuxtjs/google-analytics/-/google-analytics-2.2.0.tgz",+ "integrity": "sha512-Ds166zi7KAwc23gHOkKHovSdMEDJS55UJGkowT4IfVAOCE00l65J3fKI9t2P9+O5cdokXTadNiMLGZV5QM731Q==",+ "requires": {+ "vue-analytics": "^5.16.2"+ }+ },"@nuxtjs/proxy": {"version": "1.3.3","resolved": "https://registry.npmjs.org/@nuxtjs/proxy/-/proxy-1.3.3.tgz",@@ -9523,6 +9531,11 @@"resolved": "https://registry.npmjs.org/vue/-/vue-2.6.10.tgz","integrity": "sha512-ImThpeNU9HbdZL3utgMCq0oiMzAkt1mcgy3/E6zWC/G6AaQoeuFdsl9nDhTDU3X1R6FK7nsIUuRACVcjI+A2GQ=="},+ "vue-analytics": {+ "version": "5.17.2",+ "resolved": "https://registry.npmjs.org/vue-analytics/-/vue-analytics-5.17.2.tgz",+ "integrity": "sha512-Vfbn5laOG8OVetrBNRfV64y/N5VVyw1PPC4LiowZFh58UOsfsGH8w+ZZn0pyMelSZmz9uxkgG5dNnce4bwJ6jg=="+ },"vue-client-only": {"version": "2.0.0","resolved": "https://registry.npmjs.org/vue-client-only/-/vue-client-only-2.0.0.tgz",diff --git a/package.json b/package.jsonindex 04019a966..0b4031675 100644--- a/package.json+++ b/package.json@@ -15,6 +15,7 @@},"dependencies": {"@nuxtjs/axios": "^5.6.0",+ "@nuxtjs/google-analytics": "^2.2.0","@nuxtjs/pwa": "^3.0.0-beta.19","@nuxtjs/toast": "^3.2.1","highlight.js": "^9.15.10",diff --git a/pages/index.vue b/pages/index.vueindex e8fa3ade8..60f7df3c6 100644--- a/pages/index.vue+++ b/pages/index.vue@@ -177,8 +177,8 @@</ul><ul v-for="(value, key) in response.headers" :key="key"><li>- <label for="value">{{key}}</label>- <input id="value" :value="value" name="value" readonly>+ <label :for="key">{{key}}</label>+ <input :id="key" :value="value" :name="key" readonly></li></ul><ul v-if="response.body">@@ -689,9 +689,7 @@async sendRequest() {if (!this.isValidURL) {this.$toast.error('URL is not formatted properly', {- icon: 'error',- position: 'bottom-center',- duration: 1000,+ icon: 'error'});return;}@@ -806,9 +804,7 @@this.response.status = error.message;this.response.body = "See JavaScript console (F12) for details.";this.$toast.error('Something went wrong!', {- icon: 'error',- position: 'bottom-center',- duration: 1000,+ icon: 'error'});}},@@ -838,9 +834,7 @@removeRequestHeader(index) {this.headers.splice(index, 1)this.$toast.error('Deleted', {- icon: 'delete',- position: 'bottom-center',- duration: 1000,+ icon: 'delete'});},addRequestParam() {@@ -853,9 +847,7 @@removeRequestParam(index) {this.params.splice(index, 1)this.$toast.error('Deleted', {- icon: 'delete',- position: 'bottom-center',- duration: 1000,+ icon: 'delete'});},addRequestBodyParam() {@@ -868,9 +860,7 @@removeRequestBodyParam(index) {this.bodyParams.splice(index, 1)this.$toast.error('Deleted', {- icon: 'delete',- position: 'bottom-center',- duration: 1000,+ icon: 'delete'});},formatRawParams(event) {@@ -904,20 +894,12 @@title: `Postwoman`,text: `Postwoman • API request builder at ${time} on ${date}`,url: window.location.href- }).then(() => {- this.$toast.success('Thanks for sharing!', {- icon: 'share',- position: 'bottom-center',- duration: 1000,- });- })+ }).then(() => {}).catch(console.error);} else {this.$refs.copyRequest.innerHTML = this.copiedButton + '<span>Copied</span>';this.$toast.success('Copied to clipboard', {- icon: 'done',- position: 'bottom-center',- duration: 1000,+ icon: 'done'});var dummy = document.createElement('input');document.body.appendChild(dummy);@@ -931,9 +913,7 @@copyRequestCode() {this.$refs.copyRequestCode.innerHTML = this.copiedButton + '<span>Copied</span>';this.$toast.success('Copied to clipboard', {- icon: 'done',- position: 'bottom-center',- duration: 1000,+ icon: 'done'});this.$refs.generatedCode.select();document.execCommand("copy");@@ -942,9 +922,7 @@copyResponse() {this.$refs.copyResponse.innerHTML = this.copiedButton + '<span>Copied</span>';this.$toast.success('Copied to clipboard', {- icon: 'done',- position: 'bottom-center',- duration: 1000,+ icon: 'done'});// Creates a textarea elementvar aux = document.createElement("textarea");@@ -1041,9 +1019,7 @@} catch (error) {this.showModal = false;this.$toast.error('cURL is not formatted properly', {- icon: 'error',- position: 'bottom-center',- duration: 1000,+ icon: 'error'});}},@@ -1080,9 +1056,7 @@this.rawParams = '';}this.$toast.info('Cleared', {- icon: 'clear_all',- position: 'bottom-center',- duration: 1000,+ icon: 'clear_all'});}},diff --git a/pages/websocket.vue b/pages/websocket.vueindex a23e380ba..6ab90ee45 100644--- a/pages/websocket.vue+++ b/pages/websocket.vue@@ -127,9 +127,7 @@ts: (new Date()).toLocaleTimeString()}];this.$toast.success('Connected', {- icon: 'sync',- position: 'bottom-center',- duration: 1000,+ icon: 'sync'});};this.socket.onerror = (event) => {@@ -144,9 +142,7 @@ts: (new Date()).toLocaleTimeString()});this.$toast.error('Disconnected', {- icon: 'sync_disabled',- position: 'bottom-center',- duration: 1000,+ icon: 'sync_disabled'});};this.socket.onmessage = (event) => {@@ -159,9 +155,7 @@} catch (ex) {this.handleError(ex);this.$toast.error('Something went wrong!', {- icon: 'error',- position: 'bottom-center',- duration: 1000,+ icon: 'error'});}},diff --git a/static/screenshot1.png b/static/screenshot1.pngindex bcde40905..76069047f 100644Binary files a/static/screenshot1.png and b/static/screenshot1.png differdiff --git a/static/screenshot2.png b/static/screenshot2.pngindex c480f51f9..7fcbb78c2 100644Binary files a/static/screenshot2.png and b/static/screenshot2.png differdiff --git a/travis.js b/travis.jsdeleted file mode 100644index 4b886b3dd..000000000--- a/travis.js+++ /dev/null@@ -1,8 +0,0 @@-var http = require('http');-http.createServer(function (req, res) {- res.writeHead(200, {- 'Content-Type': 'text/plain'- });- res.end('Travis!\n'); // build should pass now!-}).listen(1337, '127.0.0.1');-console.log('Server running at http://127.0.0.1:1337/');