-
Notifications
You must be signed in to change notification settings - Fork 0
/
README
26 lines (22 loc) · 800 Bytes
/
README
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
Simple Format Live Preview
by Jarrett Meyer
------------------------------------------------------------
This is my first Prototype class for putting together a live
preview for Rails' simple_format() text helper method.
------------------------------------------------------------
<html>
<body>
<form id="my-form">
<textarea id="my-textarea"></textarea>
<div id="my-live-preview"></div>
</form>
<script type="text/javascript" src="./path/to/prototype.js"></script>
<script type="text/javascript" src="./path/to/simple-format-preview.js"></script>
<script type="text/javascript">
new SimpleFormatPreview('my-textarea', 'my-live-preview');
</script>
</body>
</html>
------------------------------------------------------------
Licensed under MIT-style license. See license.txt for more
details.