Running a javascript "Locally"


(Francois Meehan) #1

Hi all!

I have done a projet running on a tablet with text animated by typed.js invoked from the WEB. Works great but now the customer wants to disable networking on the device. How can I run typed.js locally?

This is what I have in the Head HTML

<head>
	<meta name="viewport" content="user-scalable=no, initial-scale=1.0, width=320" />
	<!-- Files added by the Resource Library -->
	<script type="text/javascript" src="${resourcesFolderName}/typed.js"></script>
	<!-- Custom Fonts -->
	<link href='https://fonts.googleapis.com/css?family=Oswald&subset=latin' rel='stylesheet' type='text/css'>
        <script src="https://code.jquery.com/jquery-2.1.4.min.js"></script>
	<script src="${resourcesFolderName}/typed.js"></script>
</head>

Thanks in advance,

François


(Mark Hunte) #2

Just putting the typed.js file in your resources will automatically place the code in the head. you do not need to put it there yourself.

Notice this line in grey text in your head, thats the file ref placed there by hype.

<script type="text/javascript" src="${resourcesFolderName}/typed.js"></script>

You can remove your line of code referring to the same file.

Apart from that what is the actual issue you are gettingre


#3

If you’re using a dedicated device for a Hype document, check out these solutions under iOS: Displaying a Tumult Hype document in a Kiosk or as an app


(Francois Meehan) #4

Thanks a million! Works perfectly…

François