jsc-0.1.0.0: High level interface for webkit-javascriptcore

Safe HaskellNone

Language.Javascript.JSC.String

Contents

Description

JavaScript string conversion functions

Synopsis

Documentation

class MakeStringRef a where

Anything that can be used to make a JavaScript string reference

Methods

makeStringRef :: a -> JSStringRef

Instances

MakeStringRef String 
MakeStringRef Text 
MakeStringRef JSStringRef

If we already have a JSStringRef we are fine

Data.Text helpers

strToText :: MonadIO m => JSStringRef -> m Text

Convert a JavaScript string to a Haskell Text

textToStr :: Text -> JSStringRef

Convert a Haskell Text to a JavaScript string