Skip to content

Improvement suggestions for d-decompose.js #10

Open
@igavrysh

Description

@igavrysh
  • change introspect function so that it can handle objects included
  • change introspect function so that it can handle recursive objects
  • parseLines improvement so that it can process more than one space b/w parameter name and data type
  • add support for curried functions multiline structure
    e.g.
'use strict';

const currdObj = { 
	common: {
			sum:  (
			// Partial sum apply, use first argument
			x // first argument which should support summation opertaion
			// Example: sum(1)
			// Returns: function(y) { return 1 + y }
		) => (
			// Apply curreied sum to second argument
			y // second argument which should support summation operation
			// Example: sum(1)(2)
			// Returns: 3
		) => (
			x + y
		) 
	}
};

introspect(currdObj)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions