Skip to content

Latest commit

 

History

History
35 lines (27 loc) · 796 Bytes

File metadata and controls

35 lines (27 loc) · 796 Bytes

cljsjs/pako

[cljsjs/pako "2.0.4-0"] ;; latest release

This jar comes with deps.cljs as used by the Foreign Libs feature of the ClojureScript compiler. After adding the above dependency to your project you can require the packaged library like so:

(ns application.core
  (:require cljsjs.pako))

Usage

; to deflate and return a Uint8Array:
(.gzip js/pako source-str (clj->js {:name "loerun ipsum"}))
; to deflate and return a string:
(.gzip js/pako source-str (clj->js {:name "loerun ipsum" :text true}))
; to inflate and return a string:
(.ungzip js/pako deflated-unint8array (clj->js {:text true}))