mirror of
https://github.com/extism/extism.git
synced 2026-04-23 03:00:11 -04:00
11 lines
222 B
Ruby
11 lines
222 B
Ruby
require './lib/extism'
|
|
require 'json'
|
|
|
|
manifest = {
|
|
:wasm => [{:path => "../wasm/code.wasm"}]
|
|
}
|
|
plugin = Plugin.new(manifest)
|
|
res = JSON.parse(plugin.call("count_vowels", ARGV[0] || "this is a test"))
|
|
puts res['count']
|
|
|