npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

golorry

v1.0.0

Published

golorry by vue

Downloads

6

Readme

holdno logo Holdno:vue-upload-qiniu

Attention:This project uses the uploading service of Qiniu,BUT it is NOT the official product of Qiniu Inc. This is a vue2 component project You can use this component in vue2 for uploading some pictures to your own Qiniu space This is my first public project and my first English document Just for fun : P This component does not guarantee the codes can be run properly after you copy them due to it relies on the module relation. As it is a component, you can reference the "vue-upload-qiniu" component to your own project according to the "README" example.

<holdno-upload></holdno-upload>
<script>
// get vue-upload-qiniu component
import holdnoUpload from '../../components/holdnoUpload'
</script>

The useful files are in this directory /src/pages/create/uploadToQiniu.vue vue upload component by Qiniu js-sdk

Requirements:

  • http://cdn.staticfile.org/Plupload/2.1.1/plupload.full.min.js
  • http://cdn.staticfile.org/qiniu-js-sdk/1.0.14-beta/qiniu.min.js

start

Install npm You can search 'install npm' by Baidu or Google :) Install webpack

$ npm install webpack -g

Install vue click here Clone vue-upload-qiniu

git clone [email protected]:holdnoWby/vue-upload-qiniu.git
https://github.com/holdnoWby/vue-upload-qiniu.git

Config

vi project/build/webpack.base.conf.js

let webpackConfig = {
  externals: {
    "Qiniu": "Qiniu"
  }
}

Requirements (after annotation:upload)

vue cli -> root/index.html

<!DOCTYPE html>
<html>
  <head>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width,initial-scale=1,user-scalable=0">
    <meta name="apple-mobile-web-app-capable" content="yes">
    <meta content="telephone=no" name="format-detection" />
    <meta name="apple-mobile-web-app-status-bar-style" content="white">
    <link rel="apple-touch-icon-precomposed" href="/static/img/apple-touch-icon-114x114-precomposed.png">
    <title>集合云</title>
    <link rel="stylesheet" href="/static/css/font-awesome-4.5.0/css/font-awesome.css">
    <link rel="stylesheet" href="/static/css/holdno.css">
  </head>
  <body>
    <div id="app"></div>
    <!--upload-->
    <script src="http://cdn.staticfile.org/Plupload/2.1.1/plupload.full.min.js"></script>
    <script src="http://cdn.staticfile.org/qiniu-js-sdk/1.0.14-beta/qiniu.min.js"></script>
    <!-- built files will be auto injected -->
  </body>
</html>

Demo code

Please fill the configuration option title: String, // upload component title picOption: Function, // click picture call back getFiles: String, // get uploaded img url (return array) uploadingText: String, // uploading show text domain: String, // Qiniu space bind url uptokenUrl: String // get Qiniu upload token (http request url)

<template>
  <div>
    <div class="golorry__title-alert">
      一经发布不可修改
    </div>
    <holdno-upload 
      title="图片上传" 
      :picOption="picOption" 
      getFiles="getFiles" 
      uploadingText="上传中..." 
      domain="https://img.holdno.com" 
      uptokenUrl="/Api/gettoken"
    ></holdno-upload>
  </div>
</template>

<script>
// get vue-upload-qiniu component
import holdnoUpload from '../../components/holdnoUpload'

export default {
  components: {
    holdnoUpload
  },
  data () {
    return {
      files: [],
    }
  },
  methods: {
    // click pictures call back
    picOption (files, index) {
      console.log(files)
    },
    // get uploaded img url (files: array)
    getFiles (files) {
      console.log(files)
      this.files = files
    }
  }
}
</script>

<style>
/* write your css */
</style>

Demo show

demo pic demo pic

Demo view

This project still under development When it is completed you can open it here.