Skip to content
Related Articles

Related Articles Drag & Drop starteffect Option

View Discussion
Improve Article
Save Article
  • Last Updated : 25 Nov, 2020
View Discussion
Improve Article
Save Article

This Drag & Drop starteffect Option is used to define the function which is called when a suitable drag-gable element starts being dragged. The function can be used to define any effect.


{ starteffect: effectFunction }


  • effectFunction: This value defines the function that contains the effect to be shown when the drag-gable is being starts being dragged.

The below example illustrates Drag & Drop starteffect Option:



<!DOCTYPE html>
    <script type="text/javascript" 
    <script type="text/javascript" 
    <script type="text/javascript">
        window.onload = function () {
                .each(function (item) {
                    new Draggable(item, {
                        revert: true,
                        // Define the effect to be used
                        // when the dragging starts
                        starteffect: function (element) {
                            new Effect.Opacity(element,
                                    from: 0,
                                    to: 1.0,
                                    duration: 5
<body style="text-align: center;">
        <h1 style="color: green">
        <p>A Computer Science Portal
            for Geeks
    <strong> Drag & Drop
        starteffect Option
    <div id="draggables">
        <img src=


My Personal Notes arrow_drop_up
Recommended Articles
Page :

Start Your Coding Journey Now!