none
JavaScript API reference for HTML Client

    General discussion

  • Can anyone say whether\when we might get a full JavaScript API reference for msls.js?  Sorta like this:

    JavaScript API reference for SharePoint 2013

    Or at least when the javascript code will be added to the existing LS docs.  The team blog is nice, and these forums are great (thanks to community members as we've seen little-to-no js from LS team in the forums.  Since Huy's departure, that is)

    Beyond those, correct me if I'm wrong, there is zero reference material for HTML client.

    Does anyone else find the reference material lacking?

    Thanks,

    Josh

    Saturday, January 25, 2014 6:26 PM

All replies

  • See:

    HTML LightSwitch Documentation for MSLS.JS

    Also my book contains information that was mostly provided by the team. Most of the content is available freely on my site. Huy takes up a large chunk toward the end (I basically held up the book for 2 months because of the information he provided) but Stephen Provine and Joe Binder provided most of the information in the first half.

    The msls is actually just a piece of "JavaScript programming" with LightSwitch. It wasn't until I did work on Creating Advanced LightSwitch HTML Screen Templates (this was the result of major effort by the team at Microsoft to get this information to me) that I really saw this.

    I think the lack of traditional documentation is because the framework is a rapidly moving target. However the team works overtime to get stuff out there. Basically while you can really get a lot out of LightSwitch by making API calls, the primary use case is to use the designer and very little code. This scenario is fully covered in the official documentation and the JavaScript you do need is documented at: How to: Modify an HTML Screen by Using Code.


    Unleash the Power - Get the LightSwitch HTML Client book

    http://LightSwitchHelpWebsite.com

    Saturday, January 25, 2014 8:19 PM
  • Thanks Michael for your reply.

    Asside from your book, which I'm sure is nice, we've seen all of this.  We make use of these resources, including your website, regularly.  The SoftLanding msls.js documentation is a perfect example of the community filling a need, namely the lack of documentation for the javascript client.  We're very grateful for folks who are putting the info out there as best they can, including yourself,  but it's no substitute for proper documentation. 

    I find the How to: Modify an HTML Screen by Using Code page in the LS docs to be a composite of code examples most of which debuted in other posts - either on the team blog or these forums.  Again we're happy it's there and we refer to it frequently.  Thanks to the team for putting it together, but it's by no means all 'the javascript you do need' regardless of whether 'designer-no-code' is the primary use case (which I think is debatable).

    You mentioned your blog post  'was the result of major effort by the team at Microsoft to get this information to me'.  A major effort for you and your blog is great and it will help a number of people.  However, we need major-general effort to get more information to everyone via proper documentation on msdn.

    I think we can all (LS team included) agree on that fact.  So the question remains whether\when this will happen.

    Best Regards,

    Josh

    Monday, January 27, 2014 10:42 PM
  •  However, we need major-general effort to get more information to everyone via proper documentation on msdn.

    I think we can all (LS team included) agree on that fact.  So the question remains whether\when this will happen.

    Because I don't see the "rapidly moving target" (web browser changes/major feature set changes like Office 365/SharePoint)  situation getting any better, I would be surprised if they are able to change the way they are documenting it now (blog posts/Forums/providing information to book writers).

    However, I do not know, I am just guessing :)


    Unleash the Power - Get the LightSwitch HTML Client book

    http://LightSwitchHelpWebsite.com

    Monday, January 27, 2014 11:05 PM
  • With all due respect, you're kidding right?  While I too am not certain the situation will change, I definitely don't buy the 'moving target' bit.

    They can document the hundreds classes in dozens of js scripts for SharePoint API (which change drastically about every other year) but cannot document a single script for lightswitch?

    Does that mean I should become a book writer so I can then participate in major efforts to get info needed to do my dev job?

    Seriously now... I think many LS Lovers would like to hear from a member of the LS team whether\when documentation is forthcoming. 

    Monday, January 27, 2014 11:20 PM
  • With all due respect, you're kidding right?  While I too am not certain the situation will change, I definitely don't buy the 'moving target' bit.

    They can document the hundreds classes in dozens of js scripts for SharePoint API (which change drastically about every other year) but cannot document a single script for lightswitch?

    Does that mean I should become a book writer so I can then participate in major efforts to get info needed to do my dev job?

    Seriously now... I think many LS Lovers would like to hear from a member of the LS team whether\when documentation is forthcoming. 

    Well let me back off a bit. I am only making guesses. For all I know they could release something tomorrow :)


    Unleash the Power - Get the LightSwitch HTML Client book

    http://LightSwitchHelpWebsite.com

    Monday, January 27, 2014 11:26 PM
  • Hi Josh,

    Beth Massi pointed me to this post. I'm the guy (yes, only one) responsible for LightSwitch documentation(among other things). I'm sorry to say that it's highly unlikely that you will ever see API reference documentation for LightSwitch. It's a matter of both demand and resources.

    First, we aren't seeing much demand for API docs. Research shows that code examples are the number one request, and our current approach is to provide code examples for the tasks that developers want to accomplish with LightSwitch.

    Second, the SharePoint API documentation is supported by several writers, and ours is only supported part-time by me - with the much-appreciated support of numerous members of our product team. Why? I don't know, but I would guess that SharePoint API's are considered more important from a market penetration standpoint than LightSwitch API's.

    Bottom line - I'm here to help you as best I can. Tell me what you are trying to accomplish with LightSwitch, and I'll do my best (with the support of our awesome team) to provide documentation that enables you to accomplish those tasks.

    Also, if you really feel that LightSwitch API docs should be a higher priority, please feel free to post a request on Connect. If enough people agree, I'd like nothing more than to get the resources to properly document the LightSwitch API's.

    Regards,


    Steve Hoag Microsoft aka the Lights Witch (IEnumerable of Newt)


    p.s. And I should add - API documentation can never equal the value added by the incredibly smart members of this community. I can sit here and imagine what you want to do with LightSwitch, but those of you "out in the trenches" can (and do) provide examples that are likely way more valuable than what I can provide. What I can do is curate those examples to make it easier for others to be successful with LightSwitch.
    Tuesday, February 25, 2014 7:57 AM
    Owner
  • Steve,

    Firstly, thanks very much for your reply and thanks to Beth for the poke.  Too often, when the answer is no, none is given.  It's refreshing to have an answer - even if it's not the one we hope for.

    Second, I hope my thankfulness for the resources that are coming from the team came across in my comments above.  All of the blogs and team member contributions in these forums are very much appreciated.  The Team blog has really stepped up with a handful of nice js material in the past few weeks.  Thanks for that!

    I know a comparison to the SharePoint goliath isn't fair, but it is the best example of MSFT .js reference that I could find and I'm familiar with it - referring to it often.

    Coming from older MS environments with greater market penetration such as SharePoint and Access, I'm accustomed to referring to official reference material to aid my understanding of existing code examples and also to chart a theory for those problems where examples are not just a 'bingle' away.

    While examples are helpful to solve a single problem, they don't do much to help newcomers to understand the purpose of each object and what each method does.  As a result, I argue there are a lot of creative ideas that never surface as examples in the community because we didn't know that object is there or that helpful method exists.  With full reference material available, I think you'd see more code examples from the community.

    Anyway, thank again for your reply.  I'll make a suggestion.  Is it Connect or UserVoice that the LS team is using for backlog suggestions at this point?

    I'd like to see more docs about the query objects in HTML Client including filter method.  Specifically, How to apply a filter to a VC on the screen

    TIA,

    Josh


    • Edited by joshbooker Tuesday, February 25, 2014 2:39 PM
    Tuesday, February 25, 2014 12:28 PM
  • Hi Josh,

    I don't disagree that well-done reference documentation can be very helpful, but unfortunately I'm not the one prioritizing our resources.

    And yes, I meant UserVoice, not Connect - old habits die hard ;-)

    Regards,


    Steve Hoag Microsoft aka the Lights Witch (IEnumerable of Newt)

    Tuesday, February 25, 2014 6:21 PM
    Owner
  • Steve Hoag is our hero!  Cannot wait to check this out.  Now if you could just get them to expose everything, you could document even more!  Thanks Steve!

    LightSwitch HTML Client API Reference Released:

    http://blogs.msdn.com/b/lightswitch/archive/2014/05/22/lightswitch-html-client-api-reference-released.aspx


    • Edited by joshbooker Thursday, May 22, 2014 5:16 PM sp
    Thursday, May 22, 2014 5:16 PM