1.0.8 • Published 6 years ago

arraybuffer-loader v1.0.8

Weekly downloads
6,585
License
MIT
Repository
github
Last release
6 years ago

ArrayBuffer loader for webpack

NPM

npm Travis Build status Dependency Status devDependency Status Maintainability Greenkeeper badge

Supported Platforms

  • Modern Browsers (IE >= 10)
  • Node.js

Getting Started

$ yarn add arraybuffer-loader

or

$ npm install arraybuffer-loader --save-dev

Usage

If you read only the specific extensions (e.g. wasm), please add loader in webpack.config.js.

module: {
  rules: [
    {
      test: /\.png$/,
      loaders: ['arraybuffer-loader'],
    },
  ],
},

Or if reading an arbitrary extension, use require.

const buffer = require('arraybuffer!./data.dat')
const array = new Uint8Array(buffer)

See also offical document Loaders.

For .wasm file

Webpack 4 or later has embedded WASM parser. So, please set type: 'javascript/auto' when use arraybuffer-loader.

module: {
  rules: [
    {
      test: /\.wasm$/,
      type: 'javascript/auto',
      loaders: ['arraybuffer-loader'],
    },
  ],
},

License

MIT © Pine Mizune

@wincax8968/scratch-vmmircoai-guimircoai-vmscratch-gui-freerangeglitchyscratch-gui@everything-registry/sub-chunk-1165blockzie-guiwiinblock-vmscratch-guisuny-guisuny-vmsuyuan-vm@cybergenios/scratch-guiitch-scratch-guijsfluidsircbloq-vmscratch-gui-astrowysebee-vmstemvn-devices-vmtowneditor-guitowneditor-vm@bbge/vm@codioedu/scratch-storage@codioedu/scratch-vmwawu-scratch-gui@finos/perspective-webpack-plugin@hapticsynaptic/braceletmaker-gui@hapticsynaptic/braceletmaker-vm@intesso/scratch-vm@mavenomics/chart-parts@jpmorganchase/perspective-webpack-plugin@jsrsc/scratch-vm@olli-vn/scratch-vm@raspberrypifoundation/scratch-gui@sondregj/flare-react@rockpack/compilermodi-scratch-vmminecraft-storeys-scratch-guiminecraft-storeys-scratch-vmmicy-vmmicropythonopenblock-guiopenblock-vmscalez-guiscalez-runtimescratch-arduino-vmscratch-arduino-guiscratch-storagescratch-gui-cntscratch-gui-groundhogscratch-gui-liaoscratch-gui-okagvscratch-gui-pearupscratch-vmscratch-vm-cobascratch-vm-dabanscratch-vm-dingdangcodescratch-vm-gakkoscratch-vm-groundhogscratch-vm-jxnscratch-vm-runkidscratch-vm-syncscratch-vm-wlxscratch-yusj-vmscratchhw-guiscratchhw-vmscratch-vm-xxbcscratch-vmzhrapzz-storagerobopro-vmrobopro-guipool-scratch-guipool-scratch-vmpyatch-vmshan-scratch-guigovin-guigovin-vmht-scratch-vmhappycode-storagehappycode-vmhcbot-vmhcbot2023-vmkulbot-guikulbot-vmkoala-vm@wdr-data/scratch-storage@wdr-data/scratch-vm@turbowarp/scratch-storage@team-monolith/scratch-gui@team-monolith/scratch-vm@zerocat/scratch-storageakid-guiakid-vmaircbloq-vmartie-scratch-vmcoba-scratch-virtual-machineclipcc-guiclipcc-storageclipcc-vmcoba-scratch-vm
1.0.8

6 years ago

1.0.7

7 years ago

1.0.6

7 years ago

1.0.4

7 years ago

1.0.3

7 years ago

1.0.2

7 years ago

1.0.1

7 years ago

1.0.0

8 years ago

0.2.2

8 years ago

0.2.1

9 years ago

0.2.0

9 years ago

0.1.1

9 years ago

0.1.0

9 years ago