Skip to content

BosNaufal/vue-file-base64

master
Switch branches/tags

Name already in use

A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?
Code

Latest commit

 

Git stats

Files

Permalink
Failed to load latest commit information.
Type
Name
Latest commit message
Commit time
 
 
src
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

vue file base64

Vue Component for Converting Files to base64. It's based on Dev Mozilla Website

DEMO

Install

You can import vue-file-base64.vue to your vue component file like this and process it with your preprocessor.

You can install it via NPM

npm install vue-file-base64

Import Module

import fileBase64 from 'vue-file-base64'
// Or
var fileBase64 = require('vue-file-base64');

Usage

<template>

  <file-base64
    v-bind:multiple="true"
    v-bind:done="getFiles">
  </file-base64>

</template>


<script>

  import fileBase64 from 'vue-file-base64';

  export default {

    components: { fileBase64 },

    methods: {
      getFiles(files){
        console.log(files);
      }
    }
  };

</script>

Props

multiple (Boolean)

Is your component support multiple file?

done (Function)

Callback Function When File has done proceed

Thank You for Making this useful~

Let's talk about some projects with me

Just Contact Me At:

License

MIT Copyright (c) 2016 - forever Naufal Rabbani

About

Vue Component for Convert File to base64

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published