Is it possible to bind/setup/init featherlight without also opening the modal?
Currently var modal = $.featherlight($target,config)
binds and then opens.
I have worked around it for now by immediately invoking modal.close()
but this feels hacky.
Possible options:
1) New config option openOnBind (true/false)
2) Bind should not open by default - user can choose to use .open() afterwards as needed.
I have also tried var modal = $target.featherlight(config)
but
both $target.open()
and modal.open()
then fail - neither contain the featherlight object/instance.
Where is the featherlight instance hiding? :)
Fiddled: http://jsfiddle.net/eybb104r/2/
P.S. The context for this is launching a modal based on the presence of a cookie, so I need to bind a modal without a DOM element trigger.