GithubHelp home page GithubHelp logo

ncri / nested_form_fields Goto Github PK

View Code? Open in Web Editor NEW
308.0 9.0 70.0 190 KB

Dynamically add and remove nested has_many association fields in a Ruby on Rails form

License: MIT License

Ruby 59.04% JavaScript 1.67% CoffeeScript 8.78% CSS 22.92% HTML 7.58%

nested_form_fields's Introduction

Nested Form Fields Build Status

This Rails gem helps creating forms for models with nested has_many associations.

It uses jQuery to dynamically add and remove nested associations.

  • Works for arbitrarily deeply nested associations (tested up to 4 levels).
  • Works with form builders like simple_form.
  • Requires Ruby 1.9+ and the Rails asset pipeline.

Installation

Add this line to your application's Gemfile:

gem 'nested_form_fields'

And then execute:

$ bundle

In your application.js file add:

//= require nested_form_fields

Rails 5.1+

You will need to install jQuery as Rails dropped it from its default stack.

Add to Gemfile:

gem 'jquery-rails'

Execute:

$ bundle

Add to application.js:

//= require jquery3
//= require jquery_ujs

Usage

Assume you have a user model with nested videos:

class User < ActiveRecord::Base
  has_many :videos
  accepts_nested_attributes_for :videos, allow_destroy: true
end

Use the nested_fields_for helper inside your user form to add the video fields:

= form_for @user do |f|
  = f.nested_fields_for :videos do |ff|
    = ff.text_field :video_title
    ..

Links to add and remove fields can be added using the add_nested_fields_link and remove_nested_fields_link helpers:

= form_for @user do |f|
  = f.nested_fields_for :videos do |ff|
    = ff.remove_nested_fields_link
    = ff.text_field :video_title
    ..
  = f.add_nested_fields_link :videos

Note that remove_nested_fields_link needs to be called within the nested_fields_for call and add_nested_fields_link outside of it via the parent builder.

Link Customization

You can change the link text of remove_nested_fields_link and add_nested_fields_link like this:

...
  ff.remove_nested_fields_link 'Remove me'
  ...
f.add_nested_fields_link :videos, 'Add another funtastic video'

You can add classes/attributes to the remove_nested_fields_link and add_nested_fields_link like this:

...
  ff.remove_nested_fields_link 'Remove me', class: 'btn btn-danger', role: 'button'
  ...
f.add_nested_fields_link :videos, 'Add another funtastic video', class: 'btn btn-primary', role: 'button'

You can supply a block to the remove_nested_fields_link and the add_nested_fields_link helpers, as you can with link_to:

= ff.remove_nested_fields_link do
  Remove me %span.icon-trash

You can add a data-confirm attribute to the remove_nested_fields_link if you want the user to confirm whenever they remove a nested field:

= ff.remove_nested_fields_link 'Remove me', data: { confirm: 'Are you sure?' }

Custom Container

You can specify a custom container to add nested forms into, by supplying an id via the data-insert-into attribute of the add_nested_fields_link:

f.add_nested_fields_link :videos, 'Add another funtastic video', data: { insert_into: '<container_id>' }

Custom Fields Wrapper

You can change the type of the element wrapping the nested fields using the wrapper_tag option:

= f.nested_fields_for :videos, wrapper_tag: :div do |ff|

The default wrapper element is a fieldset. To add legend element to the fieldset use:

= f.nested_fields_for :videos, legend: "Video" do |ff|

You can pass options like you would to the content_tag method by nesting them in a :wrapper_options hash:

= f.nested_fields_for :videos, wrapper_options: { class: 'row' } do |ff|

Rails 4 Parameter Whitelisting

If you are using Rails 4 remember to add {{ NESTED_MODEL }}_attributes and the attributes to the permitted params. If you want to destroy the nested model you should add :_destroy and :id. For example:

# app/views/users/_form.haml.erb
= form_for @user do |f|
  = f.nested_fields_for :videos do |ff|
    = ff.remove_nested_fields_link
    = ff.text_field :video_title
    ..
  = f.add_nested_fields_link :videos
# app/controllers/users_controller
..
def user_params
    params.require(:user)
        .permit(:name,:email,videos_attributes:[:video_title,:_destroy,:id])
#                            ^^^                 ^^^           ^^^
#                            nested model attrs
#                                                             they will let you delete the nested model
end

Events

There are four JavaScript events firing before and after addition/removal of the fields in the nested_form_fields namespace:

  • fields_adding
  • fields_added
  • fields_removing
  • fields_removed

The events fields_added and fields_removed are triggered on the element being added or removed. The events bubble up so you can listen for them on any parent element. This makes it easy to add listeners when you have multiple nested_form_fields on the same page.

CoffeeScript samples:

# Listen on an element
initializeSortable -> ($el)
  $el.sortable(...)
  $el.on 'fields_added.nested_form_fields', (event, param) ->
    console.log event.target # The added field
    console.log $(this)      # $el

# Listen on document
$(document).on "fields_added.nested_form_fields", (event, param) ->
  switch param.object_class
    when "video"
      console.log "Video object added"
    else
      console.log "INFO: Fields were successfully added, callback not handled."

You can pass any additional data to the event's callback. This may be useful if you trigger them programmatically. Example:

# Trigger button click programmatically and pass an object `{hello: 'world'}`
$('.add_nested_fields_link').trigger('click', [{hello: 'world'}])

# Listen for the event
$(document).on "fields_added.nested_form_fields", (event, param) ->
  console.log param.additional_data #=> {hello: 'world'}

Index replacement string

Sometimes your code needs to know what index it has when it is instantiated onto the page. HTML data elements may need to point to other form elements for instance. This is needed for integration with rails3-jquery-autocomplete.

To enable string substitution with the current index use the magic string __nested_field_for_replace_with_index__.

Contributing

  1. Fork it
  2. Create your feature branch (git checkout -b my-new-feature)
  3. Commit your changes (git commit -am 'Added some feature')
  4. Push to the branch (git push origin my-new-feature)
  5. Create new Pull Request

Contributers

https://github.com/ncri/nested_form_fields/graphs/contributors

nested_form_fields's People

Contributors

aaronklaassen avatar bahanix avatar cprodhomme avatar daniel-sullivan avatar deep-spaced avatar dustinbrownman avatar hamptonmakes avatar jensljungblad avatar jperrine avatar lessless avatar linuus avatar mebezac avatar montulli avatar ncri avatar olegantonyan avatar simon0191 avatar tamisoft avatar tomriley avatar will89 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

nested_form_fields's Issues

Templates break when nesting inside a regular Rails fields_for

I'm having some trouble with deeply nested form fields. It works fine when nesting only using nested_fields_for but if I add a regular fields_for in between, the generated <script> template tag breaks.

form_for @resource do |f|
  f.nested_fields_for :foo do |ff|
    ff.fields_for :bar do |fff|
      fff.nested_fields_for :baz do |ffff|
        # stuff
      end
    end
  end
end

In this case, bar is a belongs_to relation on foo, which means I cannot use nested_fields_for which expects a relation.

how to access the index attribute for each nested form?

I have the following

form_for(@user) do |f|
...template code for each user...
f.nested_fields_for :attendees do |ff|
...template code for each attendee...

and I just want to access the index of each attendee in order to create customized classes, ids, etc. Would have thought this would be ff.index (I saw there's an index attribute for the FormBuilder rails class). But when I use this in code, it outputs nothing. Am I doing something wrong?

remove_nested_fields_link reloads page

I have a form that saves a Report with a one to many relationship with Locomotive. My nested form looks like this.

<%= f.nested_fields_for :locomotives do |l| %>
  <div class="pure-control-group">
    <%= l.label(:number, "Locomotive #") %>
    <%= l.text_field(:number) %>
  </div>

  <div class="pure-control-group">
    <%= l.label(:loco_type, "Locomotive Type") %>
    <%= l.text_field(:loco_type) %>
  </div>

  <div class="pure-control-group">
    <%= l.label(:railroad, "Locomotive Railroad") %>
    <%= l.select :railroad, options_for_select(railroads_array) %>
  </div>

  <div class="pure-control-group">
    <%= l.remove_nested_fields_link %>
  </div>
<% end %>

<div class="pure-control-group">
  <%= f.add_nested_fields_link :locomotives %>
</div>

Whenever I click on the remove link, the page simply reloads. Debugging the JavaScript, I noticed it stops on line 42 in nested_form_fields.js.coffee.

return false unless $.rails.allowAction($link)

I am not sure if this returning false actually causes the page to reload, but I do know that the rest of the function is not being executed. I am currently using jquery-rails, jquery-ui-rails, coffee-rails, and coffee-script-source. I will provide additional code as requested, but I would like to know what causes that line in your JS to return false.

Thank you.

Required fields on chrome causing form submit to fail...

An invalid form control with is not focusable.

From my reading any fields marked as 'required' will cause this error. So, is there a slick / automated way to remove the required attribute when a block of fields is hidden?

Thanks,
Rod

Assign nested element by selector?

I have a list of nested objects that need to be visually divided into multiple buckets in the UI. In my case, I'm creating multiple UL elements and dropping LI elements underneath them. Is there some way to select the element that the nested element should be assigned to, instead of just the immediate parent element? Something like this:

= f.nested_fields_for :locations do |ff|
  fieldset#existing-locations
    ul
      # add nested list elements here

  fieldset#good-locations
    ul
      # add nested list elements here

  fieldset#bad-locations
    ul
      # add nested list elements here

  = f.add_nested_fields_link :locations, 'Add existing location'
  = f.add_nested_fields_link :locations, 'Add good location'
  = f.add_nested_fields_link :locations, 'Add bad location'

missing js files

couldn't find file 'nested_form_fields'
(in ../app/assets/javascripts/application.js:15)

Coffee rails dependency

coffee-rails was added as a dependency in this commit: a80487f

In newer rails projects the gemfile depends on gem "coffee-rails", "~> 4.1.0" and nested form fields cannot be installed. Can the dependency be made more forgiving?

License missing from gemspec

RubyGems.org doesn't report a license for your gem. This is because it is not specified in the gemspec of your last release.

via e.g.

  spec.license = 'MIT'
  # or
  spec.licenses = ['MIT', 'GPL-2']

Including a license in your gemspec is an easy way for rubygems.org and other tools to check how your gem is licensed. As you can imagine, scanning your repository for a LICENSE file or parsing the README, and then attempting to identify the license or licenses is much more difficult and more error prone. So, even for projects that already specify a license, including a license in your gemspec is a good practice. See, for example, how rubygems.org uses the gemspec to display the rails gem license.

There is even a License Finder gem to help companies/individuals ensure all gems they use meet their licensing needs. This tool depends on license information being available in the gemspec. This is an important enough issue that even Bundler now generates gems with a default 'MIT' license.

I hope you'll consider specifying a license in your gemspec. If not, please just close the issue with a nice message. In either case, I'll follow up. Thanks for your time!

Appendix:

If you need help choosing a license (sorry, I haven't checked your readme or looked for a license file), GitHub has created a license picker tool. Code without a license specified defaults to 'All rights reserved'-- denying others all rights to use of the code.
Here's a list of the license names I've found and their frequencies

p.s. In case you're wondering how I found you and why I made this issue, it's because I'm collecting stats on gems (I was originally looking for download data) and decided to collect license metadata,too, and make issues for gemspecs not specifying a license as a public service :). See the previous link or my blog post about this project for more information.

Doesn't support has_one relationships

It would be useful if the gem could also support nested forms for one-to-one relationships. If I try and create a form for such a relationship just now I get the following error:

ActionView::Template::Error (undefined method `each' for nil:NilClass):

Thanks,

James

How to access the underlying object within nested forms?

How do I access the underlying object (for example @post, @attachment, etc.) in templates? The form is working fine, no bugs, I just need to write some conditional expressions in the template to display it differently based on the data stored in the object that is referenced by the nested form. But the documentation doesn't seem to say anything about this.
Nathan

Trigger event on element instead of document

Hi!

Would it be possible to trigger the removed and added events on the removed/added element instead of on document? This would make it a bit easier to make sure you are handling the correct events. Now you have to find the added or removed element, check if it has the correct type and then do what you want to do.

I believe this is how Ryan Bates' nested_form gem works.

Model conversion doesn't take relation class name into account

I have these two relationships:

has_many :comparisons
has_many :foo_comparisons, -> { where(comparable_type: "index") }, class_name: "Comparison"

If I do

f.nested_fields_for :foo_comparisons

It tries to load a FooComparison constant, which doesn't exist, instead of going through the class_name of the relation. I believe this works in nested_forms.

Unable to install.

I'm trying to install the gem but I get this error:

Gem::RemoteFetcher::UnknownHostError: no such name (https://rubygems.org/gems/nested_form_fields-0.5.3.gem)
An error occurred while installing nested_form_fields (0.5.3), and Bundler cannot continue.
Make sure that gem install nested_form_fields -v '0.5.3' succeeds before bundling.

when I run 'gem install nested_form_fields' I get this:

ERROR: Could not find a valid gem 'nested_form_fields' (>= 0), here is why:
Unable to download data from https://rubygems.org/ - no such name (https://api.rubygems.org/specs.4.8.gz)

I'm running ruby 2.1.3 and Rails 4.1.8.

Gem doesn't work with Turbolinks

With Turbolinks present, clicking on add_nested link results in two sets of fields being created. I tried moving the load order around on the js, but that had no effect.

undefined method `gsub' for :user:Symbol

Rails 4.1 ruby 2.1.1
I'm having trouble adding nested form fields to a sign up form. I get the above error when run the rails server and load the sign up page in the browser.
nomethoderror at users sign_up

Add support for Turbolinks 5

$(document).on "page:change", ->
    nested_form_fields.bind_nested_forms_links()

won't work as Turbolinks 5 changed the event to turbolinks:load

breaks when <script> tag is inside nested_fields block

I'm using an input which appends a script tag to the input. This breaks the nested_fields <script> tag and the view.

It should be super easy to reproduce the bug, simply add a script tag to the nested_fields block, but I can provide example code if necessary :)

Breaks when nested associated model is namespaced

I get thrown an error when using the helper with an associated model that has been namespaced

class Company::Manager

  has_many :subordinates
  accept_nested_attributes_for :subordinates, allow_destroy: true

end
class Company::Subordinate

  belongs_to :manager

end
<%= f.nested_fields_for :subordinates do |ff| %>
  <div class="field">
    ... 
  </div>
<% end %>
Throws this error ...

uninitialized constant Subordinate

Works in edit but not new form

I am inheriting a project with a form with nested_form_fields.

The edit form for an existing model adds the child markup, but the new does not.

  • The collection proxy is present in both scenarios
  • It does not throw a JS error
  • fields_adding.nested_form_fields doesn't show an issue
  • fields_added.nested_form_fields doesn't show an issue

Looking at the rendered content:

  • When editing we get a fieldset and a script tag
  • When adding new we only get a script tag

The form:

= form_for [:foo, bar] do |f|
  # top level bar stuff

  .form-group
    f.nested_fields_for :bazs do |ff|
      = ff.label :name
      = ff.text_field :name

  = f.add_nested_fields_link :bazs

Not working in rails 4 with custom rails engine

I am getting the below error, where ManagementPublicIp is a model from my custom rails engine

Model:
has_many :management_public_ips, class_name: "IpamServer::ManagementPublicIp"
accepts_nested_attributes_for :management_public_ips, allow_destroy: true

ERROR"
ActionView::Template::Error (uninitialized constant ManagementPublicIp):
85: .col-lg-9
86: = f.check_box :filtering_enabled, :class => 'form-control'
87:
88: = f.nested_fields_for :management_public_ips do |ff|
89: = ff.remove_nested_fields_link
90: = ff.text_field :ip, :class => 'form-control'
91: = f.add_nested_fields_link :management_public_ips

Adding a nested entry brakes the table layout

The result on following code is that the additional nested fields seem to be added all in the first column of the table, then splitting the rest of the table to the right.

<table class="table table-striped table-condensed">
  <tr align="left">
    <th></th>
    <th><%= t('Name') %></th>
    <th><%= t('Description') %></th>
    <th><%= t('Type') %></th>
    <th><%= t('Size') %></th>
    <th><%= t('Precision') %> </th>
    <th><%= t('KeyCols') %></th>
    <th><%= t('PubCols') %></th>
  </tr>

<%= f.nested_fields_for :skills do |column| %>

  <tr align="left">
    <td><%= column.remove_nested_fields_link %></td>
    <td><%= column.text_field :name %></td>
    <td><%= column.text_field :description %></td> 
    <td><%= column.collection_select :skill_type_id, @data_types_list, :id, :name %></td> 
    <td><%= column.text_field :skill_size %></td>
    <td><%= column.text_field :skill_precision %></td>
    <td><%= column.check_box :is_key %></td>
    <td><%= column.check_box :is_published %></td>
  </tr>

<% end %>

</table>

<br/>

<%= f.add_nested_fields_link :skills %>

<br/>
<br/>
<div class="actions">
<%= f.submit %>
</div>

screenshot

In the source of html page, tag may be inserted twice:
htmlSource.txt

Thanks for help

Not submitting

I followed the instructions in the read me
I am able to add and remove fields, but i can't seem to make the data on the fields go into the database
I placed the code in the show action of my projects controller, and just to make sure there is no button or link to do such thing?

<%= form_for @project do |f| %>
<%= f.nested_fields_for :ethhs do |ff| %>
<%= ff.remove_nested_fields_link %>
<%= ff.text_field :description %>
<%= ff.number_field :amount %>
<%= ff.number_field :price %>
<%= ff.number_field :code_hh_id %>

<% end %>
<%= f.add_nested_fields_link :ethhs %>
<% end %>

I18n Simple Form Translations don't work

It doesn't look like simple form translations are compatible with this library.

Models

class PrimaryObject
  has_many secondary_objects
end

class SecondaryObject
  belongs_to :primary_object
end

My simple_form.en.yml:

en:
  simple_form:
    labels:
      primary_object:
        first_property: "First Property"
        secondary_objects:
          my_property: "Translated Label"

My Form

= simple_form_for(@primary_object, url: primary_objects_path) do |f|
  = f.input :first_property
  = f.nested_fields_for :secondary_objects do |ff|
    = ff.input :name  
  = f.add_nested_fields_link :secondary_objects

In my controller, I'm defaulting secondary_objects in my controller with two SecondaryObject.news:

class PrimaryObjectsController < ApplicationController
  def new
    @inquiry = PrimaryObject.new(
      secondary_objects: [
        SecondaryObject.new,
        SecondaryObject.new
      ]
    )
  end
end

When the page initially loads and displays these two records using nested_fields_for, they are translated as I would expect. However, when I click the add_nested_fields_link, it adds a new field with the humanized version of the field, not the translated version.

I should note that I can work around the problem by doing the following in my form file where I display SecondaryObject.name, but figured I'd see if there was anything you could do to get this working "out of the box":

= ff.input :name, label: I18n.t("simple_form.labels.primary_object.secondary_objects.name"

nesting nested forms

Is there a way to nest inside a nested form? I have a dynamic Survey application and want to have it add options for the answers, so I have a form.nested_fields_for and that works great but inside that, I have another nested_fields_for for the options. When I click to add a new question, It adds the question form (with no errors) and one fields_for for the options but the link to add options doesn't add any more options and the current last option (the one added by the add link for the questions) is constructed funny, so is rejected (by strong params) Is that a bug or it cannot add nested in nested form?

I hope I made myself clear, if not, please let me know.

Add field link does not work, closestChild gives error

I get the eroor Uncaught TypeError: $parsed_template.closestChild is not a function
If i change the line
$child_templates = $parsed_template.closestChild('.form_template');
to:
$child_templates = $parsed_template.closest('.form_template');
It works flawless

undefined method `nested_fields_for' for #<ActionView::Helpers::FormBuilder

On localhost is working like a charm, but on production I'm getting this error:

NoMethodError: undefined method `nested_fields_for' for #<ActionView::Helpers::FormBuilder:0x00000002a197b0>

I've checked and nested_form_field is correctly set on Gemfile, with rails 4 and ruby 2.1.
Here is the full trace:

[PROJECT_ROOT]/app/views/webinar_questions/_form.html.erb:35:in `block in _app_views_webinar_questions__form_html_erb__45301749637291857_47344440'
[GEM_ROOT]/gems/actionpack-4.0.0/lib/action_view/helpers/capture_helper.rb:38:in `block in capture'
[GEM_ROOT]/gems/actionpack-4.0.0/lib/action_view/helpers/capture_helper.rb:200:in `with_output_buffer'
[GEM_ROOT]/gems/actionpack-4.0.0/lib/action_view/helpers/capture_helper.rb:38:in `capture'
[GEM_ROOT]/gems/actionpack-4.0.0/lib/action_view/helpers/form_helper.rb:435:in `form_for'
[PROJECT_ROOT]/app/views/webinar_questions/_form.html.erb:1:in `_app_views_webinar_questions__form_html_erb__45301749637291857_47344440'
[GEM_ROOT]/gems/actionpack-4.0.0/lib/action_view/template.rb:143:in `block in render'
[GEM_ROOT]/gems/activesupport-4.0.0/lib/active_support/notifications.rb:159:in `block in instrument'
[GEM_ROOT]/gems/activesupport-4.0.0/lib/active_support/notifications/instrumenter.rb:20:in `instrument'
[GEM_ROOT]/gems/activesupport-4.0.0/lib/active_support/notifications.rb:159:in `instrument'
[GEM_ROOT]/gems/actionpack-4.0.0/lib/action_view/template.rb:141:in `render'
[GEM_ROOT]/gems/actionpack-4.0.0/lib/action_view/renderer/partial_renderer.rb:306:in `render_partial'
[GEM_ROOT]/gems/actionpack-4.0.0/lib/action_view/renderer/partial_renderer.rb:279:in `block in render'
[GEM_ROOT]/gems/actionpack-4.0.0/lib/action_view/renderer/abstract_renderer.rb:38:in `block in instrument'
[GEM_ROOT]/gems/activesupport-4.0.0/lib/active_support/notifications.rb:159:in `block in instrument'
[GEM_ROOT]/gems/activesupport-4.0.0/lib/active_support/notifications/instrumenter.rb:20:in `instrument'
[GEM_ROOT]/gems/activesupport-4.0.0/lib/active_support/notifications.rb:159:in `instrument'
[GEM_ROOT]/gems/actionpack-4.0.0/lib/action_view/renderer/abstract_renderer.rb:38:in `instrument'
[GEM_ROOT]/gems/actionpack-4.0.0/lib/action_view/renderer/partial_renderer.rb:278:in `render'
[GEM_ROOT]/gems/actionpack-4.0.0/lib/action_view/renderer/renderer.rb:47:in `render_partial'
[GEM_ROOT]/gems/actionpack-4.0.0/lib/action_view/helpers/rendering_helper.rb:27:in `render'
[PROJECT_ROOT]/app/views/webinar_questions/new.html.erb:3:in `_app_views_webinar_questions_new_html_erb___1863366937932933150_47380300'
[GEM_ROOT]/gems/actionpack-4.0.0/lib/action_view/template.rb:143:in `block in render'
[GEM_ROOT]/gems/activesupport-4.0.0/lib/active_support/notifications.rb:159:in `block in instrument'
[GEM_ROOT]/gems/activesupport-4.0.0/lib/active_support/notifications/instrumenter.rb:20:in `instrument'
[GEM_ROOT]/gems/activesupport-4.0.0/lib/active_support/notifications.rb:159:in `instrument'
[GEM_ROOT]/gems/actionpack-4.0.0/lib/action_view/template.rb:141:in `render'
[GEM_ROOT]/gems/actionpack-4.0.0/lib/action_view/renderer/template_renderer.rb:49:in `block (2 levels) in render_template'
[GEM_ROOT]/gems/actionpack-4.0.0/lib/action_view/renderer/abstract_renderer.rb:38:in `block in instrument'
[GEM_ROOT]/gems/activesupport-4.0.0/lib/active_support/notifications.rb:159:in `block in instrument'
[GEM_ROOT]/gems/activesupport-4.0.0/lib/active_support/notifications/instrumenter.rb:20:in `instrument'
[GEM_ROOT]/gems/activesupport-4.0.0/lib/active_support/notifications.rb:159:in `instrument'
[GEM_ROOT]/gems/actionpack-4.0.0/lib/action_view/renderer/abstract_renderer.rb:38:in `instrument'
[GEM_ROOT]/gems/actionpack-4.0.0/lib/action_view/renderer/template_renderer.rb:48:in `block in render_template'
[GEM_ROOT]/gems/actionpack-4.0.0/lib/action_view/renderer/template_renderer.rb:56:in `render_with_layout'
[GEM_ROOT]/gems/actionpack-4.0.0/lib/action_view/renderer/template_renderer.rb:47:in `render_template'
[GEM_ROOT]/gems/actionpack-4.0.0/lib/action_view/renderer/template_renderer.rb:17:in `render'
[GEM_ROOT]/gems/actionpack-4.0.0/lib/action_view/renderer/renderer.rb:42:in `render_template'
[GEM_ROOT]/gems/actionpack-4.0.0/lib/action_view/renderer/renderer.rb:23:in `render'
[GEM_ROOT]/gems/actionpack-4.0.0/lib/abstract_controller/rendering.rb:127:in `_render_template'
[GEM_ROOT]/gems/actionpack-4.0.0/lib/action_controller/metal/streaming.rb:219:in `_render_template'
[GEM_ROOT]/gems/actionpack-4.0.0/lib/abstract_controller/rendering.rb:120:in `render_to_body'
[GEM_ROOT]/gems/actionpack-4.0.0/lib/action_controller/metal/rendering.rb:33:in `render_to_body'
[GEM_ROOT]/gems/actionpack-4.0.0/lib/action_controller/metal/renderers.rb:26:in `render_to_body'
[GEM_ROOT]/gems/actionpack-4.0.0/lib/abstract_controller/rendering.rb:97:in `render'
[GEM_ROOT]/gems/actionpack-4.0.0/lib/action_controller/metal/rendering.rb:16:in `render'
[GEM_ROOT]/gems/actionpack-4.0.0/lib/action_controller/metal/instrumentation.rb:41:in `block (2 levels) in render'
[GEM_ROOT]/gems/activesupport-4.0.0/lib/active_support/core_ext/benchmark.rb:12:in `block in ms'
/home/deployer/.rvm/rubies/ruby-2.1.8/lib/ruby/2.1.0/benchmark.rb:294:in `realtime'
[GEM_ROOT]/gems/activesupport-4.0.0/lib/active_support/core_ext/benchmark.rb:12:in `ms'
[GEM_ROOT]/gems/actionpack-4.0.0/lib/action_controller/metal/instrumentation.rb:41:in `block in render'
[GEM_ROOT]/gems/actionpack-4.0.0/lib/action_controller/metal/instrumentation.rb:84:in `cleanup_view_runtime'
[GEM_ROOT]/gems/activerecord-4.0.0/lib/active_record/railties/controller_runtime.rb:25:in `cleanup_view_runtime'
[GEM_ROOT]/gems/actionpack-4.0.0/lib/action_controller/metal/instrumentation.rb:40:in `render'
[GEM_ROOT]/gems/wicked_pdf-0.11.0/lib/wicked_pdf/pdf_helper.rb:23:in `render_with_wicked_pdf'
[GEM_ROOT]/gems/actionpack-4.0.0/lib/action_controller/metal/implicit_render.rb:10:in `default_render'
[GEM_ROOT]/gems/actionpack-4.0.0/lib/action_controller/metal/responder.rb:233:in `default_render'
[GEM_ROOT]/gems/actionpack-4.0.0/lib/action_controller/metal/responder.rb:161:in `to_html'
[GEM_ROOT]/gems/actionpack-4.0.0/lib/action_controller/metal/responder.rb:154:in `respond'
[GEM_ROOT]/gems/actionpack-4.0.0/lib/action_controller/metal/responder.rb:147:in `call'
[GEM_ROOT]/gems/actionpack-4.0.0/lib/action_controller/metal/mime_responds.rb:330:in `respond_with'
[PROJECT_ROOT]/app/controllers/webinar_questions_controller.rb:24:in `new'
[GEM_ROOT]/gems/actionpack-4.0.0/lib/action_controller/metal/implicit_render.rb:4:in `send_action'
[GEM_ROOT]/gems/actionpack-4.0.0/lib/abstract_controller/base.rb:189:in `process_action'
[GEM_ROOT]/gems/actionpack-4.0.0/lib/action_controller/metal/rendering.rb:10:in `process_action'
[GEM_ROOT]/gems/actionpack-4.0.0/lib/abstract_controller/callbacks.rb:18:in `block in process_action'
[GEM_ROOT]/gems/activesupport-4.0.0/lib/active_support/callbacks.rb:433:in `_run__3111297450711535740__process_action__callbacks'
[GEM_ROOT]/gems/activesupport-4.0.0/lib/active_support/callbacks.rb:80:in `run_callbacks'
[GEM_ROOT]/gems/actionpack-4.0.0/lib/abstract_controller/callbacks.rb:17:in `process_action'
[GEM_ROOT]/gems/actionpack-4.0.0/lib/action_controller/metal/rescue.rb:29:in `process_action'
[GEM_ROOT]/gems/actionpack-4.0.0/lib/action_controller/metal/instrumentation.rb:31:in `block in process_action'
[GEM_ROOT]/gems/activesupport-4.0.0/lib/active_support/notifications.rb:159:in `block in instrument'
[GEM_ROOT]/gems/activesupport-4.0.0/lib/active_support/notifications/instrumenter.rb:20:in `instrument'
[GEM_ROOT]/gems/activesupport-4.0.0/lib/active_support/notifications.rb:159:in `instrument'
[GEM_ROOT]/gems/actionpack-4.0.0/lib/action_controller/metal/instrumentation.rb:30:in `process_action'
[GEM_ROOT]/gems/actionpack-4.0.0/lib/action_controller/metal/params_wrapper.rb:245:in `process_action'
[GEM_ROOT]/gems/activerecord-4.0.0/lib/active_record/railties/controller_runtime.rb:18:in `process_action'
[GEM_ROOT]/gems/actionpack-4.0.0/lib/abstract_controller/base.rb:136:in `process'
[GEM_ROOT]/gems/actionpack-4.0.0/lib/abstract_controller/rendering.rb:44:in `process'
[GEM_ROOT]/gems/actionpack-4.0.0/lib/action_controller/metal.rb:195:in `dispatch'
[GEM_ROOT]/gems/actionpack-4.0.0/lib/action_controller/metal/rack_delegation.rb:13:in `dispatch'
[GEM_ROOT]/gems/actionpack-4.0.0/lib/action_controller/metal.rb:231:in `block in action'
[GEM_ROOT]/gems/actionpack-4.0.0/lib/action_dispatch/routing/route_set.rb:80:in `call'
[GEM_ROOT]/gems/actionpack-4.0.0/lib/action_dispatch/routing/route_set.rb:80:in `dispatch'
[GEM_ROOT]/gems/actionpack-4.0.0/lib/action_dispatch/routing/route_set.rb:48:in `call'
[GEM_ROOT]/gems/actionpack-4.0.0/lib/action_dispatch/journey/router.rb:71:in `block in call'
[GEM_ROOT]/gems/actionpack-4.0.0/lib/action_dispatch/journey/router.rb:59:in `each'
[GEM_ROOT]/gems/actionpack-4.0.0/lib/action_dispatch/journey/router.rb:59:in `call'
[GEM_ROOT]/gems/actionpack-4.0.0/lib/action_dispatch/routing/route_set.rb:655:in `call'
[GEM_ROOT]/gems/newrelic_rpm-3.12.1.298/lib/new_relic/agent/instrumentation/middleware_tracing.rb:67:in `call'
[GEM_ROOT]/gems/omniauth-1.3.1/lib/omniauth/strategy.rb:186:in `call!'
[GEM_ROOT]/gems/omniauth-1.3.1/lib/omniauth/strategy.rb:164:in `call'
[GEM_ROOT]/gems/newrelic_rpm-3.12.1.298/lib/new_relic/agent/instrumentation/middleware_tracing.rb:67:in `call'
[GEM_ROOT]/gems/omniauth-1.3.1/lib/omniauth/strategy.rb:186:in `call!'
[GEM_ROOT]/gems/omniauth-1.3.1/lib/omniauth/strategy.rb:164:in `call'
[GEM_ROOT]/gems/newrelic_rpm-3.12.1.298/lib/new_relic/agent/instrumentation/middleware_tracing.rb:67:in `call'
[GEM_ROOT]/gems/newrelic_rpm-3.12.1.298/lib/new_relic/rack/agent_hooks.rb:30:in `traced_call'
[GEM_ROOT]/gems/newrelic_rpm-3.12.1.298/lib/new_relic/agent/instrumentation/middleware_tracing.rb:67:in `call'
[GEM_ROOT]/gems/newrelic_rpm-3.12.1.298/lib/new_relic/rack/browser_monitoring.rb:32:in `traced_call'
[GEM_ROOT]/gems/newrelic_rpm-3.12.1.298/lib/new_relic/agent/instrumentation/middleware_tracing.rb:67:in `call'
[GEM_ROOT]/gems/warden-1.2.4/lib/warden/manager.rb:35:in `block in call'
[GEM_ROOT]/gems/warden-1.2.4/lib/warden/manager.rb:34:in `catch'
[GEM_ROOT]/gems/warden-1.2.4/lib/warden/manager.rb:34:in `call'
[GEM_ROOT]/gems/newrelic_rpm-3.12.1.298/lib/new_relic/agent/instrumentation/middleware_tracing.rb:67:in `call'
[GEM_ROOT]/gems/rack-1.5.5/lib/rack/etag.rb:23:in `call'
[GEM_ROOT]/gems/newrelic_rpm-3.12.1.298/lib/new_relic/agent/instrumentation/middleware_tracing.rb:67:in `call'
[GEM_ROOT]/gems/rack-1.5.5/lib/rack/conditionalget.rb:25:in `call'
[GEM_ROOT]/gems/newrelic_rpm-3.12.1.298/lib/new_relic/agent/instrumentation/middleware_tracing.rb:67:in `call'
[GEM_ROOT]/gems/rack-1.5.5/lib/rack/head.rb:11:in `call'
[GEM_ROOT]/gems/newrelic_rpm-3.12.1.298/lib/new_relic/agent/instrumentation/middleware_tracing.rb:67:in `call'
[GEM_ROOT]/gems/actionpack-4.0.0/lib/action_dispatch/middleware/params_parser.rb:27:in `call'
[GEM_ROOT]/gems/newrelic_rpm-3.12.1.298/lib/new_relic/agent/instrumentation/middleware_tracing.rb:67:in `call'
[GEM_ROOT]/gems/actionpack-4.0.0/lib/action_dispatch/middleware/flash.rb:241:in `call'
[GEM_ROOT]/gems/newrelic_rpm-3.12.1.298/lib/new_relic/agent/instrumentation/middleware_tracing.rb:67:in `call'
[GEM_ROOT]/gems/rack-1.5.5/lib/rack/session/abstract/id.rb:225:in `context'
[GEM_ROOT]/gems/rack-1.5.5/lib/rack/session/abstract/id.rb:220:in `call'
[GEM_ROOT]/gems/newrelic_rpm-3.12.1.298/lib/new_relic/agent/instrumentation/middleware_tracing.rb:67:in `call'
[GEM_ROOT]/gems/actionpack-4.0.0/lib/action_dispatch/middleware/cookies.rb:486:in `call'
[GEM_ROOT]/gems/newrelic_rpm-3.12.1.298/lib/new_relic/agent/instrumentation/middleware_tracing.rb:67:in `call'
[GEM_ROOT]/gems/activerecord-4.0.0/lib/active_record/query_cache.rb:36:in `call'
[GEM_ROOT]/gems/newrelic_rpm-3.12.1.298/lib/new_relic/agent/instrumentation/middleware_tracing.rb:67:in `call'
[GEM_ROOT]/gems/activerecord-4.0.0/lib/active_record/connection_adapters/abstract/connection_pool.rb:626:in `call'
[GEM_ROOT]/gems/newrelic_rpm-3.12.1.298/lib/new_relic/agent/instrumentation/middleware_tracing.rb:67:in `call'
[GEM_ROOT]/gems/actionpack-4.0.0/lib/action_dispatch/middleware/callbacks.rb:29:in `block in call'
[GEM_ROOT]/gems/activesupport-4.0.0/lib/active_support/callbacks.rb:373:in `_run__545859884188748164__call__callbacks'
[GEM_ROOT]/gems/activesupport-4.0.0/lib/active_support/callbacks.rb:80:in `run_callbacks'
[GEM_ROOT]/gems/actionpack-4.0.0/lib/action_dispatch/middleware/callbacks.rb:27:in `call'
[GEM_ROOT]/gems/newrelic_rpm-3.12.1.298/lib/new_relic/agent/instrumentation/middleware_tracing.rb:67:in `call'
[GEM_ROOT]/gems/actionpack-4.0.0/lib/action_dispatch/middleware/remote_ip.rb:76:in `call'
[GEM_ROOT]/gems/newrelic_rpm-3.12.1.298/lib/new_relic/agent/instrumentation/middleware_tracing.rb:67:in `call'
[GEM_ROOT]/gems/newrelic_rpm-3.12.1.298/lib/new_relic/agent/instrumentation/middleware_tracing.rb:67:in `call'
[GEM_ROOT]/gems/actionpack-4.0.0/lib/action_dispatch/middleware/debug_exceptions.rb:17:in `call'
[GEM_ROOT]/gems/newrelic_rpm-3.12.1.298/lib/new_relic/agent/instrumentation/middleware_tracing.rb:67:in `call'
[GEM_ROOT]/gems/actionpack-4.0.0/lib/action_dispatch/middleware/show_exceptions.rb:30:in `call'
[GEM_ROOT]/gems/newrelic_rpm-3.12.1.298/lib/new_relic/agent/instrumentation/middleware_tracing.rb:67:in `call'
[GEM_ROOT]/gems/railties-4.0.0/lib/rails/rack/logger.rb:38:in `call_app'
[GEM_ROOT]/gems/railties-4.0.0/lib/rails/rack/logger.rb:21:in `block in call'
[GEM_ROOT]/gems/activesupport-4.0.0/lib/active_support/tagged_logging.rb:67:in `block in tagged'
[GEM_ROOT]/gems/activesupport-4.0.0/lib/active_support/tagged_logging.rb:25:in `tagged'
[GEM_ROOT]/gems/activesupport-4.0.0/lib/active_support/tagged_logging.rb:67:in `tagged'
[GEM_ROOT]/gems/railties-4.0.0/lib/rails/rack/logger.rb:21:in `call'
[GEM_ROOT]/gems/newrelic_rpm-3.12.1.298/lib/new_relic/agent/instrumentation/middleware_tracing.rb:67:in `call'
[GEM_ROOT]/gems/actionpack-4.0.0/lib/action_dispatch/middleware/request_id.rb:21:in `call'
[GEM_ROOT]/gems/newrelic_rpm-3.12.1.298/lib/new_relic/agent/instrumentation/middleware_tracing.rb:67:in `call'
[GEM_ROOT]/gems/rack-1.5.5/lib/rack/methodoverride.rb:21:in `call'
[GEM_ROOT]/gems/newrelic_rpm-3.12.1.298/lib/new_relic/agent/instrumentation/middleware_tracing.rb:67:in `call'
[GEM_ROOT]/gems/rack-1.5.5/lib/rack/runtime.rb:17:in `call'
[GEM_ROOT]/gems/newrelic_rpm-3.12.1.298/lib/new_relic/agent/instrumentation/middleware_tracing.rb:67:in `call'
[GEM_ROOT]/gems/activesupport-4.0.0/lib/active_support/cache/strategy/local_cache.rb:83:in `call'
[GEM_ROOT]/gems/newrelic_rpm-3.12.1.298/lib/new_relic/agent/instrumentation/middleware_tracing.rb:67:in `call'
[GEM_ROOT]/gems/actionpack-4.0.0/lib/action_dispatch/middleware/static.rb:64:in `call'
[GEM_ROOT]/gems/newrelic_rpm-3.12.1.298/lib/new_relic/agent/instrumentation/middleware_tracing.rb:67:in `call'
[GEM_ROOT]/gems/newrelic_rpm-3.12.1.298/lib/new_relic/agent/instrumentation/middleware_tracing.rb:67:in `call'
[GEM_ROOT]/gems/railties-4.0.0/lib/rails/engine.rb:511:in `call'
[GEM_ROOT]/gems/railties-4.0.0/lib/rails/application.rb:97:in `call'
[GEM_ROOT]/gems/newrelic_rpm-3.12.1.298/lib/new_relic/agent/instrumentation/middleware_tracing.rb:67:in `call'
[GEM_ROOT]/gems/unicorn-5.0.1/lib/unicorn/http_server.rb:562:in `process_client'
[GEM_ROOT]/gems/unicorn-5.0.1/lib/unicorn/http_server.rb:658:in `worker_loop'
[GEM_ROOT]/gems/unicorn-5.0.1/lib/unicorn/http_server.rb:508:in `spawn_missing_workers'
[GEM_ROOT]/gems/unicorn-5.0.1/lib/unicorn/http_server.rb:519:in `maintain_worker_count'
[GEM_ROOT]/gems/unicorn-5.0.1/lib/unicorn/http_server.rb:283:in `join'
[GEM_ROOT]/gems/unicorn-5.0.1/bin/unicorn:126:in `<top (required)>'
[GEM_ROOT]/bin/unicorn:23:in `load'
[GEM_ROOT]/bin/unicorn:23:in `<main>'

add_nested_fields_link causes the page to reload

I'm having a weird issue where I have the following:

<%= f.nested_fields_for :empleados_incapacidades, wrapper_tag: "tr" do |i| %>
  <%= render "admin/empleados/empleados_incapacidades_fields", :f => i %>
<% end %>

<!-- And the link where I add  fields to the form -->
<div class="row-fluid text-left">
  <%= f.add_nested_fields_link :empleados_incapacidades, "Agregar Incapacidad", class: "btn btn-primary", id: "btn-agregar-deducciones"  %>
</div>

The issue appears when I navigate to the page where the form is rendered. When I click the add_nested_fields_link it reloads the page. For some reason, when I reload the page manually after it does it by itself, it works perfectly.

Also, when I it works, and I'm listening to the fields_added.nested_form_fields event

$(document).unbind().on "fields_added.nested_form_fields", (event, param) ->

it triggers the event twice. Is there a way to trigger the same events in a button, not a link?

Using:

Ruby 1.9.3-p551
Rails 4.1.0

Table friendy

Hi,
I try to use nested_form_fields in a <table>. But when I place the <tr> and <td> tags in a nested_fields_for, weird stuff happen. First of, my remove_nested_fields_link stops working. And when try I to add a new element through the add_nested_fields_link, the new element doesn't get wrapped with a <tr> and <td> tag which would be my expectations.

Is it possible to make nested_form_fields play nice with tables?

Error when using Generate Rails4.1 and Ruby 2.1

here is my console log

maxs-air:nested_form_fields max$ rails g model user
/Users/max/Desktop/Code/AndroidRailsGCM/nested_form_fields/config/application.rb:10:in <module:NestedFormFields>': uninitialized constant NestedFormFields::Rails::Application (NameError) from /Users/max/Desktop/Code/AndroidRailsGCM/nested_form_fields/config/application.rb:9:in<top (required)>'
from /Users/max/.rvm/gems/ruby-2.1.1/gems/spring-1.1.2/lib/spring/application.rb:82:in require' from /Users/max/.rvm/gems/ruby-2.1.1/gems/spring-1.1.2/lib/spring/application.rb:82:inpreload'
from /Users/max/.rvm/gems/ruby-2.1.1/gems/spring-1.1.2/lib/spring/application.rb:140:in serve' from /Users/max/.rvm/gems/ruby-2.1.1/gems/spring-1.1.2/lib/spring/application.rb:128:inblock in run'
from /Users/max/.rvm/gems/ruby-2.1.1/gems/spring-1.1.2/lib/spring/application.rb:122:in loop' from /Users/max/.rvm/gems/ruby-2.1.1/gems/spring-1.1.2/lib/spring/application.rb:122:inrun'
from /Users/max/.rvm/gems/ruby-2.1.1/gems/spring-1.1.2/lib/spring/application/boot.rb:18:in <top (required)>' from /Users/max/.rvm/rubies/ruby-2.1.1/lib/ruby/2.1.0/rubygems/core_ext/kernel_require.rb:55:inrequire'
from /Users/max/.rvm/rubies/ruby-2.1.1/lib/ruby/2.1.0/rubygems/core_ext/kernel_require.rb:55:in require' from -e:1:in

'
maxs-air:nested_form_fields max$

Any ideas on what might be causing this issue?

Same child fields get repeated when updating.

When we are updating the parent with some changes to child table. The child entry gets repeated.

For example

I have question which has multiple answers.

When i edit the form and try to update. The same answer records get updated twice. Any idea on the issue

Cannot access attributes of nested object

When trying to gain access to the attributes of an associated object whilst updating its parent, it is possible to access the associated object, but not its attributes. For instance, the following works:

<%= f.nested_fields_for :charges do |cf| %>
          <%= cf.object.account %> 
      <% end %>

Whereas this fails with undefined method 'id' for nil:NilClass:

<%= f.nested_fields_for :charges do |cf| %>
          <%= cf.object.account.id %> 
 <% end %>

Laws of Demeter aside, this feels profoundly odd.

When saving nested_form_fields console stays BEGIN

Hi friends, I need your help please. I'm using the gem 'nested_form_fields' and 'mysql2', no problem could save by creating a new record or update it. I have been improving much the HTML interface several days and today I find the news that I can just update a record and not create a new one with other nested records. This leaves me in the console and stays there. As if doing something or as if stopped by a breakpoint.

I've already tried changing the settings:
tx_isolation of REPEATABLE-READ to READ-UNCOMMITTED in MySQL
Attached a picture of the console.

errorconsola
relaciones

entidad

Lot of duplicated classes

Hi!

When I use this gem, for each nested form I add it gets more and more classes appended.

Example:
first item: class="nested_fields nested_mailing_mailing_items"
second item: class="nested_fields nested_mailing_mailing_items nested_fields nested_mailing_mailing_items"
third item: class="nested_fields nested_mailing_mailing_items nested_fields nested_mailing_mailing_items nested_fields nested_mailing_mailing_items"

and so on...

Is this the intended behavior? It seems weird to duplicate the classes for each item added.

Get the link clicked in the fields_added.nested_form_fields event

Would it be possible to get the original click event together with the fields_added.nested_form_fields event?

I have two different add_nested_fields_link links, and I would like to know which one was clicked.

$('body').on 'click', '.add_nested_fields_link', (originalEvent) ->
  ...
  $parsed_template.trigger("fields_added.nested_form_fields", {object_class: object_class, added_index: added_index, association_path: association_path, originalEvent: originalEvent});

Or something like that

Marked for deletion not persisted on re-render

If an object is marked for deletion but another object fails then the object marked for deletion is rendered again

i.e.
I have nested comments that require the body attribute to be present
Three db persisted comments
mark one for deletion
add another without a body
click save
page renders with the three persisted comments and the new one with a validation error

Limit add link

is there a way to limit f.add_nested_fields_link to a number? Meaning, let's say someone clicks the f.add_nested_fields_link link, I only want the person to add 1 nested object. How can I make the link not be shown after clicked x amount of times?

nested_fields not rendering.

I have a Survey class with has_many :questions :

class Survey < ActiveRecord::Base
...
  has_many :questions
  accepts_nested_attributes_for :questions, allow_destroy: true
...
end

And a form to create survey:

<%= bootstrap_form_for(@survey, url: game_surveys_path) do |f| %>
  <%= f.text_field(:name) %>
  <%= f.text_area(:data) %>
  <%= f.nested_fields_for :questions, wrapper_tag: :div  do |fq| %>
    <%= fq.text_field(:statement)  %>
    <%= fq.collection_select(:type_id, Type.all, :id, :kind,{:prompt=>"Select Game Category"}) %>
  <% end %>
  <%= f.hidden_field(:game_id, :value=>@game.id) %><br/>
<%= f.submit %>
<% end %>

I have no errors but nested fields are not rendered. Any idea? Thx

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.