Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Change needs to be added to FormlyTemplateOptions #279

Closed
jrgleason opened this issue Nov 23, 2016 · 0 comments · Fixed by #280
Closed

Change needs to be added to FormlyTemplateOptions #279

jrgleason opened this issue Nov 23, 2016 · 0 comments · Fixed by #280

Comments

@jrgleason
Copy link
Contributor

jrgleason commented Nov 23, 2016

I'm submitting a ... (check one with "x")

[X] bug report
[ ] feature request
[ ] support request

Current behavior
The code is as follows...

export interface FormlyFieldConfig {
   ...
   change?: Function;
   ...
}

however, per http://plnkr.co/edit/OfcprFL35FxG3cHpF0Hz?p=preview, if I try to use this property it doesn't work like this this.connectorFields[0].change. I instead need to add it to the FormlyTemplateOptions like this... this.connectorFields[0].templateOptions.change.

Now in plunker this works OK but if you are transpiling with something like webpack you get...

(27,49): error TS2339: Property 'change' does not exist on type 'FormlyTemplateOptions'

so I instead have to use this.connectorFields[0].templateOptions["change"]

Expected behavior
I would like to be able to use this.connectorFields[0].templateOptions.change instead

Minimal reproduction of the problem with instructions

See plunker

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging a pull request may close this issue.

2 participants