[Github-comments] [geany/geany] Is destructering in mixin intended / supported for foreseeable future? (#2083)
StephenCarboni
notifications at xxxxx
Wed Feb 6 14:31:18 UTC 2019
In trying to give named parameters to mixins, I noticed you can get away doing this:
```pug
mixin simpleField({label, name, isRequired, leftIconClass})
.field
label.label(for=`txt-${name}`)= label
div(class=`control ${leftIconClass ? "has-icons-left" : ""}`)
input.input(
id=`txt-${name}`,
name= name,
type='text',
required= isRequired)
if leftIconClass
span.icon.is-small.is-left
i.fas(class= leftIconClass)
+simpleField({ label: "Full Name", name: "host-full-name", isRequired: true, leftIconClass: "fa-user" })
```
Is there a good chance this is going to break in the future?
--
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/geany/geany/issues/2083
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.geany.org/pipermail/github-comments/attachments/20190206/91691d34/attachment-0001.html>
More information about the Github-comments
mailing list