netzke/netzke-core

Complex method in #netzke

      def netzke(name, config = {})
        @rendered_classes ||= []

        # If we are the first netzke call on the page, reset components hash in the session.
        # WON'T WORK, because it breaks the browser "back" button
Found in Netzke::Railz::ActionViewExt - About 2 hrs to fix

Long or complex methods can make code harder to understand. In most circumstances, methods are best as a small chunk of code (the "how") with a clear, understandable name (the "what"). Long methods can also lead to duplication, as it's harder to reuse logic that is tightly coupled to surrounding code.

Refactorings

Read More

Complex method in #invoke_endpoint

    def invoke_endpoint(endpoint, params, configs = [])
      self.client = Netzke::Core::EndpointResponse.new

      if has_endpoint?(endpoint)
        client.netzke_set_result(send("#{endpoint}_endpoint", *params))
Found in Netzke::Core::Services - About 2 hrs to fix

Long or complex methods can make code harder to understand. In most circumstances, methods are best as a small chunk of code (the "how") with a clear, understandable name (the "what"). Long methods can also lead to duplication, as it's harder to reuse logic that is tightly coupled to surrounding code.

Refactorings

Read More

Complex method in #css_included

      def css_included
        # Prevent re-including code that was already included by the parent
        # (thus, only include those JS files when include_js was defined in the current class, not in its ancestors)
        ((singleton_methods(false).map(&:to_sym).include?(:include_css) ? include_css : [] ) + css_config.required_files).inject(""){ |r, path| r + File.new(path).read + "\n"}
      end
Found in Netzke::Core::Stylesheets::ClassMethods - About 2 hrs to fix

Long or complex methods can make code harder to understand. In most circumstances, methods are best as a small chunk of code (the "how") with a clear, understandable name (the "what"). Long methods can also lead to duplication, as it's harder to reuse logic that is tightly coupled to surrounding code.

Refactorings

Read More

Complex class definition

require 'active_support/core_ext'
require 'netzke/core/ruby_ext'
require 'netzke/core/client_code'
require 'netzke/core/stylesheets'
require 'netzke/core/services'
Found in Netzke::Base - About 2 hrs to fix

    Complex class definition

    module Netzke::Core
      # Any Netzke component can define child components, which can either be statically nested in the compound layout (e.g. as different regions of the 'border' layout), or dynamically loaded at a request (as is the advanced search panel in Basepack::GridPanel, for example).
      #
      # == Defining a component
      #
    Found in Netzke::Core::Composition - About 2 hrs to fix

      Complex method in #action

            def action(*args, &block)
              args.each{|name| action(name)} if args.length > 1
      
              name = args.first
      
      
      Found in Netzke::Core::Actions::ClassMethods - About 1 hr to fix

      Long or complex methods can make code harder to understand. In most circumstances, methods are best as a small chunk of code (the "how") with a clear, understandable name (the "what"). Long methods can also lead to duplication, as it's harder to reuse logic that is tightly coupled to surrounding code.

      Refactorings

      Read More

      Complex class definition

      module Netzke
        module Railz
          class Engine < Rails::Engine
            initializer "netzke.core" do |app|
              app.config.eager_load_paths -= ["#{app.config.root}/app/components"]
      Found in Netzke::Railz::Engine - About 1 hr to fix