1.0.0 • Published 7 years ago

js-editable v1.0.0

Weekly downloads
1
License
ISC
Repository
github
Last release
7 years ago

js-editable

dynamic editable html contents with jquery javascript

Get started

HTML header code

<link href="dist/js-editable.min.css" rel="stylesheet">
<script src="dist/js-editable.min.js"></script>

Automatic initialization

<table>
    <tr>
        <td class='editable' data-editable-group='tb1'>cell1</td>
        <td class='editable' data-editable-group='tb1'>cell2</td>
        <td class='editable' data-editable-group='tb1'>cell3</td>
    </tr>
    <tr>
        <td class='editable' data-editable-group='tb1'>cell1</td>
        <td class='editable' data-editable-group='tb1'>cell2</td>
        <td class='editable' data-editable-group='tb1'>cell3</td>
    </tr>
</table>

Manual JQuery initialization

HTML code

<table>
    <tr>
        <td class='editable-cell' data-editable-group='tb1'>cell1</td>
        <td class='editable-cell' data-editable-group='tb1'>cell2</td>
        <td class='editable-cell' data-editable-group='tb1'>cell3</td>
    </tr>
    <tr>
        <td class='editable-cell' data-editable-group='tb1'>cell1</td>
        <td class='editable-cell' data-editable-group='tb1'>cell2</td>
        <td class='editable-cell' data-editable-group='tb1'>cell3</td>
    </tr>
</table>

javascript code

$(".editable-cell").editable();
1.0.0

7 years ago