Flowdock
method

assign

Importance_1
Ruby on Rails latest stable (v6.1.7.7) - 0 notes - Class: ActionView::Helpers::PrototypeHelper::JavaScriptGenerator::GeneratorMethods

Method deprecated or moved

This method is deprecated or moved on the latest stable version. The last existing version (v3.0.9) is shown here.

These similar methods exist in v6.1.7.7:

assign(variable, value) public

Assigns the JavaScript variable the given value.

Examples:

# Generates: my_string = "This is mine!";
page.assign 'my_string', 'This is mine!'

# Generates: record_count = 33;
page.assign 'record_count', 33

# Generates: tabulated_total = 47
page.assign 'tabulated_total', @total_from_cart
Show source
Register or log in to add new notes.