This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
I included this 3 (RedCloth, ApplicationHelper, ActionView::Helpers) in my module class named PdfGenerate. | |
Followed some snippets from David at https://github.com/mileszs/wicked_pdf/issues/57 | |
Inside my show.pdf.erb from the view template I have some helper methods like | |
work_month() | |
number_to_currency() | |
My question is how does ERB result binding able to recognize these helper methods before generating it to PDF. | |
Because I always got: NoMethodError: undefined method |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import React, { Component } from 'react'; | |
import TemplateDetails from './TemplateDetails'; | |
import cx from 'classnames'; | |
class Library extends Component { | |
constructor(props) { | |
super(props); | |
this.state = { | |
templates: [], | |
selectedTemplate: null, |