Repository: aspnet/Blazor.Docs Branch: master Commit: aea3b94c7051 Files: 100 Total size: 345.5 KB Directory structure: gitextract_t_iy0_rr/ ├── .gitattributes ├── .github/ │ ├── ISSUE_TEMPLATE.md │ └── PULL_REQUEST_TEMPLATE.md ├── .gitignore ├── CNAME ├── CONTRIBUTING.md ├── LICENSE ├── LICENSE-CODE ├── README.md ├── ThirdPartyNotices ├── api/ │ ├── .gitignore │ └── index.md ├── appveyor.yml ├── community.md ├── docfx.json ├── docs/ │ ├── common/ │ │ └── samples/ │ │ └── 3.x/ │ │ └── BlazorSample/ │ │ ├── App.cshtml │ │ ├── BlazorSample.csproj │ │ ├── Components/ │ │ │ ├── ListViewTemplate.cshtml │ │ │ ├── Tab.cshtml │ │ │ ├── TabSet.cshtml │ │ │ └── TableTemplate.cshtml │ │ ├── JsInteropClasses/ │ │ │ ├── ExampleJsInterop.cs │ │ │ └── HelloHelper.cs │ │ ├── Pages/ │ │ │ ├── BlazorRocks.cshtml │ │ │ ├── BlazorRocksBase.cs │ │ │ ├── BlazorRoute.cshtml │ │ │ ├── CascadingValuesParametersTabSet.cshtml │ │ │ ├── CascadingValuesParametersTheme.cshtml │ │ │ ├── ChildComponent.cshtml │ │ │ ├── FetchData.cshtml │ │ │ ├── HeadingComponent.cshtml │ │ │ ├── Index.cshtml │ │ │ ├── JSInterop.cshtml │ │ │ ├── ParentComponent.cshtml │ │ │ ├── RazorTemplates.cshtml │ │ │ ├── RouteParameter.cshtml │ │ │ ├── TemplatedComponents.cshtml │ │ │ └── _ViewImports.cshtml │ │ ├── Program.cs │ │ ├── README.md │ │ ├── Shared/ │ │ │ ├── CascadingValuesParametersLayout.cshtml │ │ │ ├── MainLayout.cshtml │ │ │ └── NavMenu.cshtml │ │ ├── Startup.cs │ │ ├── UIInterfaces/ │ │ │ └── ITab.cs │ │ ├── UIThemeClasses/ │ │ │ └── ThemeInfo.cs │ │ ├── _ViewImports.cshtml │ │ └── wwwroot/ │ │ ├── css/ │ │ │ └── site.css │ │ ├── exampleJsInterop.js │ │ ├── index.html │ │ └── sample-data/ │ │ └── weather.json │ ├── component-libraries.md │ ├── components/ │ │ └── index.md │ ├── debugging.md │ ├── dependency-injection.md │ ├── get-started.md │ ├── host-and-deploy/ │ │ ├── configure-linker.md │ │ └── index.md │ ├── hosting-models/ │ │ └── samples_snapshot/ │ │ └── Startup.cs │ ├── hosting-models.md │ ├── index.md │ ├── introduction/ │ │ ├── faq.md │ │ └── index.md │ ├── javascript-interop.md │ ├── layouts.md │ ├── routing.md │ ├── toc.md │ └── tutorials/ │ ├── build-your-first-blazor-app/ │ │ └── samples/ │ │ └── 3.x/ │ │ └── BlazorApp1/ │ │ ├── App.cshtml │ │ ├── BlazorApp1.csproj │ │ ├── Pages/ │ │ │ ├── Counter.cshtml │ │ │ ├── FetchData.cshtml │ │ │ ├── Index.cshtml │ │ │ ├── ToDo.cshtml │ │ │ └── _ViewImports.cshtml │ │ ├── Program.cs │ │ ├── README.md │ │ ├── Shared/ │ │ │ ├── MainLayout.cshtml │ │ │ ├── NavMenu.cshtml │ │ │ └── SurveyPrompt.cshtml │ │ ├── Startup.cs │ │ ├── TodoItem.cs │ │ ├── _ViewImports.cshtml │ │ └── wwwroot/ │ │ ├── css/ │ │ │ ├── open-iconic/ │ │ │ │ ├── FONT-LICENSE │ │ │ │ ├── ICON-LICENSE │ │ │ │ ├── README.md │ │ │ │ └── font/ │ │ │ │ └── fonts/ │ │ │ │ └── open-iconic.otf │ │ │ └── site.css │ │ ├── index.html │ │ └── sample-data/ │ │ └── weather.json │ └── build-your-first-blazor-app.md ├── includes/ │ └── razor-components-preview-notice.md ├── index.md ├── releaseDocs.sh ├── src/ │ ├── Microsoft.AspNetCore.Blazor.Browser.xml │ ├── Microsoft.AspNetCore.Blazor.Server.xml │ ├── Microsoft.AspNetCore.Blazor.xml │ └── Microsoft.JSInterop.xml ├── template/ │ ├── index.html.tmpl │ └── styles/ │ └── main.css └── toc.yml ================================================ FILE CONTENTS ================================================ ================================================ FILE: .gitattributes ================================================ ############################################################################### # Set default behavior to automatically normalize line endings. ############################################################################### * text=auto ############################################################################### # Set default behavior for command prompt diff. # # This is need for earlier builds of msysgit that does not have it on by # default for csharp files. # Note: This is only used by command line ############################################################################### #*.cs diff=csharp ############################################################################### # Set the merge driver for project and solution files # # Merging from the command prompt will add diff markers to the files if there # are conflicts (Merging from VS is not affected by the settings below, in VS # the diff markers are never inserted). Diff markers may cause the following # file extensions to fail to load in VS. An alternative would be to treat # these files as binary and thus will always conflict and require user # intervention with every merge. To do so, just uncomment the entries below ############################################################################### #*.sln merge=binary #*.csproj merge=binary #*.vbproj merge=binary #*.vcxproj merge=binary #*.vcproj merge=binary #*.dbproj merge=binary #*.fsproj merge=binary #*.lsproj merge=binary #*.wixproj merge=binary #*.modelproj merge=binary #*.sqlproj merge=binary #*.wwaproj merge=binary ############################################################################### # behavior for image files # # image files are treated as binary by default. ############################################################################### #*.jpg binary #*.png binary #*.gif binary *.ico binary ############################################################################### # diff behavior for common document formats # # Convert binary document formats to text before diffing them. This feature # is only available from the command line. Turn it on by uncommenting the # entries below. ############################################################################### #*.doc diff=astextplain #*.DOC diff=astextplain #*.docx diff=astextplain #*.DOCX diff=astextplain #*.dot diff=astextplain #*.DOT diff=astextplain #*.pdf diff=astextplain #*.PDF diff=astextplain #*.rtf diff=astextplain #*.RTF diff=astextplain ================================================ FILE: .github/ISSUE_TEMPLATE.md ================================================ ================================================ FILE: .github/PULL_REQUEST_TEMPLATE.md ================================================ ================================================ FILE: .gitignore ================================================ _build/ _site/ Properties/ # Use git add -f to force override .sln when required. Not needed in most cases. # git add -f myProj.sln *.sln Project_Readme.html ## Ignore Visual Studio temporary files, build results, and ## files generated by popular Visual Studio add-ons. # User-specific files *.suo *.user *.userosscache *.sln.docstates *.vscode/ # User-specific files (MonoDevelop/Xamarin Studio) *.userprefs # Build results [Dd]ebug/ [Dd]ebugPublic/ [Rr]elease/ [Rr]eleases/ x64/ x86/ build/ bld/ [Bb]in/ [Oo]bj/ # Visual Studo 2015 cache/options directory .vs/ # MSTest test Results [Tt]est[Rr]esult*/ [Bb]uild[Ll]og.* # NUNIT *.VisualState.xml TestResult.xml # Build Results of an ATL Project [Dd]ebugPS/ [Rr]eleasePS/ dlldata.c *_i.c *_p.c *_i.h *.ilk *.meta *.obj *.pch *.pdb *.pgc *.pgd *.rsp *.sbr *.tlb *.tli *.tlh *.tmp *.tmp_proj *.log *.vspscc *.vssscc .builds *.pidb *.svclog *.scc # Chutzpah Test files _Chutzpah* # Visual C++ cache files ipch/ *.aps *.ncb *.opensdf *.sdf *.cachefile # Visual Studio profiler *.psess *.vsp *.vspx # TFS 2012 Local Workspace $tf/ # Guidance Automation Toolkit *.gpState # ReSharper is a .NET coding add-in _ReSharper*/ *.[Rr]e[Ss]harper *.DotSettings.user # JustCode is a .NET coding addin-in .JustCode # TeamCity is a build add-in _TeamCity* # DotCover is a Code Coverage Tool *.dotCover # NCrunch _NCrunch_* .*crunch*.local.xml # MightyMoose *.mm.* AutoTest.Net/ # Web workbench (sass) .sass-cache/ # Installshield output folder [Ee]xpress/ # DocProject is a documentation generator add-in DocProject/buildhelp/ DocProject/Help/*.HxT DocProject/Help/*.HxC DocProject/Help/*.hhc DocProject/Help/*.hhk DocProject/Help/*.hhp DocProject/Help/Html2 DocProject/Help/html # Click-Once directory publish/ # Publish Web Output *.[Pp]ublish.xml *.azurePubxml # TODO: Comment the next line if you want to checkin your web deploy settings # but database connection strings (with potential passwords) will be unencrypted *.pubxml *.publishproj # NuGet Packages *.nupkg # The packages folder can be ignored because of Package Restore **/packages/* # except build/, which is used as an MSBuild target. !**/packages/build/ # Uncomment if necessary however generally it will be regenerated when needed #!**/packages/repositories.config # Windows Azure Build Output csx/ *.build.csdef # Windows Store app package directory AppPackages/ # Others *.[Cc]ache ClientBin/ [Ss]tyle[Cc]op.* ~$* *~ *.dbmdl *.dbproj.schemaview *.pfx *.publishsettings node_modules/ bower_components/ # RIA/Silverlight projects Generated_Code/ # Backup & report files from converting an old project file # to a newer Visual Studio version. Backup files are not needed, # because we have git ;-) _UpgradeReport_Files/ Backup*/ UpgradeLog*.XML UpgradeLog*.htm # SQL Server files *.mdf *.ldf # Business Intelligence projects *.rdl.data *.bim.layout *.bim_*.settings # Microsoft Fakes FakesAssemblies/ # Node.js Tools for Visual Studio .ntvs_analysis.dat # Visual Studio 6 build log *.plg # Visual Studio 6 workspace options file *.opt project.lock.json **/sample/**/wwwroot/lib/ **/samples/**/wwwroot/lib/ __pycache__/ #Mac OSX .DS_Store # Windows thumbnail cache files Thumbs.db # DocFx api/.manifest _exported_templates/ ================================================ FILE: CNAME ================================================ blazor.net ================================================ FILE: CONTRIBUTING.md ================================================ # Contributing to the Blazor documentation This document covers the process for contributing to the articles and code samples that are hosted at http://blazor.net. Contributions may be as simple as typo corrections or as complex as new articles. ## How to make a simple correction or suggestion Articles are stored in the repository as markdown files. Simple changes to the content of a markdown file can be made in the browser by selecting the **Improve this Doc** link in the upper-right corner of the browser window, editing the doc on GitHub, and then submitting a pull request (PR) for the change. We will review the PR and accept it or suggest changes. ## How to make a more complex submission You'll need a basic understanding of [Git and GitHub.com](https://guides.github.com/activities/hello-world/). * Open an [issue](https://github.com/aspnet/Blazor.Docs/issues/new) describing what you want to do, such as change an existing article or create a new one. Wait for approval from the team before you invest much time. We usually request an outline for a new topic proposal. * Fork the [aspnet/Blazor.Docs](https://github.com/aspnet/Blazor.Docs/) repo and create a branch for your changes. * Submit a pull request (PR) to master with your changes. * If your PR has the label 'cla-required' assigned, [complete the Contribution License Agreement (CLA)](https://cla.dotnetfoundation.org/) * Respond to PR feedback. ## Markdown syntax Articles are written in [DocFx-flavored Markdown (DFM)](http://dotnet.github.io/docfx/spec/docfx_flavored_markdown.html), which is a superset of [GitHub-flavored Markdown (GFM)](https://guides.github.com/features/mastering-markdown/). For examples of DFM syntax for UI features commonly used in the Blazor documentation, see [Metadata and Markdown Template](https://github.com/dotnet/docs/blob/master/styleguide/template.md) in the .NET repo style guide. ## Folder structure conventions For each markdown file, there may be a folder for images and a folder for sample code. For example, if the article is *tutorials/build-your-first-blazor-app.md*, the images are in *tutorials/build-your-first-blazor-app/\_static* and the sample app project files are in *tutorials/build-your-first-blazor-app/samples/2.x* (for a 2.x versioned sample). An image in the *tutorials/build-your-first-blazor-app.md* file is rendered by the following markdown. ``` ![description of image for alt attribute](tutorials/build-your-first-blazor-app/_static/image-name.png) ``` **All** images should have [alt text](https://wikipedia.org/wiki/Alt_attribute). Markdown file names and image file names should be all lower case. Use dashes to separate words in file names. ## Internal links Internal links should use the `uid` of the target article with an xref link: ``` [link_text](xref:uid_of_the_topic) ``` For more informatin, see the [DocFX Cross Reference](http://dotnet.github.io/docfx/spec/docfx_flavored_markdown.html#cross-reference). ## Code snippets Articles frequently contain code snippets to illustrate points. DFM lets you copy code into the Markdown file or refer to a separate code file. We prefer to use separate code files whenever possible to minimize the chance of errors in the code. The code files should be stored in the repo using the folder structure described above for sample projects. Here are some examples of [DFM code snippet syntax](http://dotnet.github.io/docfx/spec/docfx_flavored_markdown.html#code-snippet) that would be used in a *tutorials/build-your-first-blazor-app.md* file. To render an entire code file as a snippet: ``` [!code-csharp[Main](tutorials/build-your-first-blazor-app/sample/Program.cs)] ``` To render a portion of a file as a snippet by using line numbers: ``` [!code-csharp[Main](tutorials/build-your-first-blazor-app/sample/Program.cs?range=1-10,20,30,40-50] [!code-html[Main](tutorials/build-your-first-blazor-app/sample/Pages/Index.cshtml?range=1-10,20,30,40-50] ``` For C# snippets, you can reference a [C# region](https://docs.microsoft.com/dotnet/csharp/language-reference/preprocessor-directives/preprocessor-region). Whenever possible, use regions rather than line numbers because line numbers in a code file tend to change and become out of sync with line number references in markdown. C# regions can be nested; and if you reference the outer region, the inner `#region` and `#endregion` directives aren't rendered in a snippet. To render a C# region named "snippet_Example": ``` [!code-csharp[Main](tutorials/build-your-first-blazor-app/sample/Program.cs?name=snippet_Example)] ``` To highlight selected lines in a rendered snippet (usually renders as yellow background color): ``` [!code-csharp[Main](tutorials/build-your-first-blazor-app/sample/Program.cs?name=snippet_Example&highlight=1-3,10,20-25)] [!code-csharp[Main](tutorials/build-your-first-blazor-app/sample/Program.cs?range=10-20&highlight=1-3] [!code-html[Main](tutorials/build-your-first-blazor-app/sample/Pages/Index.cshtml?range=10-20&highlight=1-3] [!code-javascript[Main](tutorials/build-your-first-blazor-app/sample/BlazorApp1.csproj?range=10-20&highlight=1-3] ``` ## Test your changes with DocFX Test your changes with the [DocFX command-line tool](https://dotnet.github.io/docfx/tutorial/docfx_getting_started.html#2-use-docfx-as-a-command-line-tool), which creates a locally-hosted version of the site. DocFX doesn't render style and site extensions created for docs.microsoft.com. DocFX requires the .NET Framework on Windows or Mono for Linux/macOS. ### Windows instructions * Download and unzip *docfx.zip* from [DocFX releases](https://github.com/dotnet/docfx/releases). * Add DocFX to your PATH. * In a console window, navigate to root of the repo (where the *docfx.json* file resides) and run the following command: ``` docfx --serve ``` * In a browser, navigate to `http://localhost:8080`. ### Mono instructions * Install Mono via Homebrew: ``` brew install mono ``` * Download the [latest version of DocFX](https://github.com/dotnet/docfx/releases). * Extract the archive to *$HOME/bin/docfx*. * Create a pair of aliases for **docfx** in a bash shell. The first alias is used to build the documentation. The second alias is used to build and serve the documentation. ``` alias docfx='mono $HOME/bin/docfx/docfx.exe' alias docfx-serve='mono $HOME/bin/docfx/docfx.exe --serve' ``` * Execute `docfx` from the root of the repo to build the site. Execute `docfx-serve` to view the site at `http://localhost:8080`. ## Voice and tone Our goal is to write documentation that is easily understandable by the widest possible audience. To that end, we've established guidelines for writing style that we ask our contributors to follow. For more information, see [Voice and tone guidelines](https://github.com/dotnet/docs/blob/master/styleguide/voice-tone.md) in the .NET repo. ## Microsoft Writing Style Guide The [Microsoft Writing Style Guide](https://docs.microsoft.com/style-guide/welcome/) provides writing style and terminology guidance for all forms of technology communication, including the Blazor documentation. ================================================ FILE: LICENSE ================================================ Attribution 4.0 International ======================================================================= Creative Commons Corporation ("Creative Commons") is not a law firm and does not provide legal services or legal advice. Distribution of Creative Commons public licenses does not create a lawyer-client or other relationship. Creative Commons makes its licenses and related information available on an "as-is" basis. Creative Commons gives no warranties regarding its licenses, any material licensed under their terms and conditions, or any related information. Creative Commons disclaims all liability for damages resulting from their use to the fullest extent possible. Using Creative Commons Public Licenses Creative Commons public licenses provide a standard set of terms and conditions that creators and other rights holders may use to share original works of authorship and other material subject to copyright and certain other rights specified in the public license below. The following considerations are for informational purposes only, are not exhaustive, and do not form part of our licenses. Considerations for licensors: Our public licenses are intended for use by those authorized to give the public permission to use material in ways otherwise restricted by copyright and certain other rights. Our licenses are irrevocable. Licensors should read and understand the terms and conditions of the license they choose before applying it. Licensors should also secure all rights necessary before applying our licenses so that the public can reuse the material as expected. Licensors should clearly mark any material not subject to the license. This includes other CC- licensed material, or material used under an exception or limitation to copyright. More considerations for licensors: wiki.creativecommons.org/Considerations_for_licensors Considerations for the public: By using one of our public licenses, a licensor grants the public permission to use the licensed material under specified terms and conditions. If the licensor's permission is not necessary for any reason--for example, because of any applicable exception or limitation to copyright--then that use is not regulated by the license. Our licenses grant only permissions under copyright and certain other rights that a licensor has authority to grant. Use of the licensed material may still be restricted for other reasons, including because others have copyright or other rights in the material. A licensor may make special requests, such as asking that all changes be marked or described. Although not required by our licenses, you are encouraged to respect those requests where reasonable. More_considerations for the public: wiki.creativecommons.org/Considerations_for_licensees ======================================================================= Creative Commons Attribution 4.0 International Public License By exercising the Licensed Rights (defined below), You accept and agree to be bound by the terms and conditions of this Creative Commons Attribution 4.0 International Public License ("Public License"). To the extent this Public License may be interpreted as a contract, You are granted the Licensed Rights in consideration of Your acceptance of these terms and conditions, and the Licensor grants You such rights in consideration of benefits the Licensor receives from making the Licensed Material available under these terms and conditions. Section 1 -- Definitions. a. Adapted Material means material subject to Copyright and Similar Rights that is derived from or based upon the Licensed Material and in which the Licensed Material is translated, altered, arranged, transformed, or otherwise modified in a manner requiring permission under the Copyright and Similar Rights held by the Licensor. For purposes of this Public License, where the Licensed Material is a musical work, performance, or sound recording, Adapted Material is always produced where the Licensed Material is synched in timed relation with a moving image. b. Adapter's License means the license You apply to Your Copyright and Similar Rights in Your contributions to Adapted Material in accordance with the terms and conditions of this Public License. c. Copyright and Similar Rights means copyright and/or similar rights closely related to copyright including, without limitation, performance, broadcast, sound recording, and Sui Generis Database Rights, without regard to how the rights are labeled or categorized. For purposes of this Public License, the rights specified in Section 2(b)(1)-(2) are not Copyright and Similar Rights. d. Effective Technological Measures means those measures that, in the absence of proper authority, may not be circumvented under laws fulfilling obligations under Article 11 of the WIPO Copyright Treaty adopted on December 20, 1996, and/or similar international agreements. e. Exceptions and Limitations means fair use, fair dealing, and/or any other exception or limitation to Copyright and Similar Rights that applies to Your use of the Licensed Material. f. Licensed Material means the artistic or literary work, database, or other material to which the Licensor applied this Public License. g. Licensed Rights means the rights granted to You subject to the terms and conditions of this Public License, which are limited to all Copyright and Similar Rights that apply to Your use of the Licensed Material and that the Licensor has authority to license. h. Licensor means the individual(s) or entity(ies) granting rights under this Public License. i. Share means to provide material to the public by any means or process that requires permission under the Licensed Rights, such as reproduction, public display, public performance, distribution, dissemination, communication, or importation, and to make material available to the public including in ways that members of the public may access the material from a place and at a time individually chosen by them. j. Sui Generis Database Rights means rights other than copyright resulting from Directive 96/9/EC of the European Parliament and of the Council of 11 March 1996 on the legal protection of databases, as amended and/or succeeded, as well as other essentially equivalent rights anywhere in the world. k. You means the individual or entity exercising the Licensed Rights under this Public License. Your has a corresponding meaning. Section 2 -- Scope. a. License grant. 1. Subject to the terms and conditions of this Public License, the Licensor hereby grants You a worldwide, royalty-free, non-sublicensable, non-exclusive, irrevocable license to exercise the Licensed Rights in the Licensed Material to: a. reproduce and Share the Licensed Material, in whole or in part; and b. produce, reproduce, and Share Adapted Material. 2. Exceptions and Limitations. For the avoidance of doubt, where Exceptions and Limitations apply to Your use, this Public License does not apply, and You do not need to comply with its terms and conditions. 3. Term. The term of this Public License is specified in Section 6(a). 4. Media and formats; technical modifications allowed. The Licensor authorizes You to exercise the Licensed Rights in all media and formats whether now known or hereafter created, and to make technical modifications necessary to do so. The Licensor waives and/or agrees not to assert any right or authority to forbid You from making technical modifications necessary to exercise the Licensed Rights, including technical modifications necessary to circumvent Effective Technological Measures. For purposes of this Public License, simply making modifications authorized by this Section 2(a) (4) never produces Adapted Material. 5. Downstream recipients. a. Offer from the Licensor -- Licensed Material. Every recipient of the Licensed Material automatically receives an offer from the Licensor to exercise the Licensed Rights under the terms and conditions of this Public License. b. No downstream restrictions. You may not offer or impose any additional or different terms or conditions on, or apply any Effective Technological Measures to, the Licensed Material if doing so restricts exercise of the Licensed Rights by any recipient of the Licensed Material. 6. No endorsement. Nothing in this Public License constitutes or may be construed as permission to assert or imply that You are, or that Your use of the Licensed Material is, connected with, or sponsored, endorsed, or granted official status by, the Licensor or others designated to receive attribution as provided in Section 3(a)(1)(A)(i). b. Other rights. 1. Moral rights, such as the right of integrity, are not licensed under this Public License, nor are publicity, privacy, and/or other similar personality rights; however, to the extent possible, the Licensor waives and/or agrees not to assert any such rights held by the Licensor to the limited extent necessary to allow You to exercise the Licensed Rights, but not otherwise. 2. Patent and trademark rights are not licensed under this Public License. 3. To the extent possible, the Licensor waives any right to collect royalties from You for the exercise of the Licensed Rights, whether directly or through a collecting society under any voluntary or waivable statutory or compulsory licensing scheme. In all other cases the Licensor expressly reserves any right to collect such royalties. Section 3 -- License Conditions. Your exercise of the Licensed Rights is expressly made subject to the following conditions. a. Attribution. 1. If You Share the Licensed Material (including in modified form), You must: a. retain the following if it is supplied by the Licensor with the Licensed Material: i. identification of the creator(s) of the Licensed Material and any others designated to receive attribution, in any reasonable manner requested by the Licensor (including by pseudonym if designated); ii. a copyright notice; iii. a notice that refers to this Public License; iv. a notice that refers to the disclaimer of warranties; v. a URI or hyperlink to the Licensed Material to the extent reasonably practicable; b. indicate if You modified the Licensed Material and retain an indication of any previous modifications; and c. indicate the Licensed Material is licensed under this Public License, and include the text of, or the URI or hyperlink to, this Public License. 2. You may satisfy the conditions in Section 3(a)(1) in any reasonable manner based on the medium, means, and context in which You Share the Licensed Material. For example, it may be reasonable to satisfy the conditions by providing a URI or hyperlink to a resource that includes the required information. 3. If requested by the Licensor, You must remove any of the information required by Section 3(a)(1)(A) to the extent reasonably practicable. 4. If You Share Adapted Material You produce, the Adapter's License You apply must not prevent recipients of the Adapted Material from complying with this Public License. Section 4 -- Sui Generis Database Rights. Where the Licensed Rights include Sui Generis Database Rights that apply to Your use of the Licensed Material: a. for the avoidance of doubt, Section 2(a)(1) grants You the right to extract, reuse, reproduce, and Share all or a substantial portion of the contents of the database; b. if You include all or a substantial portion of the database contents in a database in which You have Sui Generis Database Rights, then the database in which You have Sui Generis Database Rights (but not its individual contents) is Adapted Material; and c. You must comply with the conditions in Section 3(a) if You Share all or a substantial portion of the contents of the database. For the avoidance of doubt, this Section 4 supplements and does not replace Your obligations under this Public License where the Licensed Rights include other Copyright and Similar Rights. Section 5 -- Disclaimer of Warranties and Limitation of Liability. a. UNLESS OTHERWISE SEPARATELY UNDERTAKEN BY THE LICENSOR, TO THE EXTENT POSSIBLE, THE LICENSOR OFFERS THE LICENSED MATERIAL AS-IS AND AS-AVAILABLE, AND MAKES NO REPRESENTATIONS OR WARRANTIES OF ANY KIND CONCERNING THE LICENSED MATERIAL, WHETHER EXPRESS, IMPLIED, STATUTORY, OR OTHER. THIS INCLUDES, WITHOUT LIMITATION, WARRANTIES OF TITLE, MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE, NON-INFRINGEMENT, ABSENCE OF LATENT OR OTHER DEFECTS, ACCURACY, OR THE PRESENCE OR ABSENCE OF ERRORS, WHETHER OR NOT KNOWN OR DISCOVERABLE. WHERE DISCLAIMERS OF WARRANTIES ARE NOT ALLOWED IN FULL OR IN PART, THIS DISCLAIMER MAY NOT APPLY TO YOU. b. TO THE EXTENT POSSIBLE, IN NO EVENT WILL THE LICENSOR BE LIABLE TO YOU ON ANY LEGAL THEORY (INCLUDING, WITHOUT LIMITATION, NEGLIGENCE) OR OTHERWISE FOR ANY DIRECT, SPECIAL, INDIRECT, INCIDENTAL, CONSEQUENTIAL, PUNITIVE, EXEMPLARY, OR OTHER LOSSES, COSTS, EXPENSES, OR DAMAGES ARISING OUT OF THIS PUBLIC LICENSE OR USE OF THE LICENSED MATERIAL, EVEN IF THE LICENSOR HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH LOSSES, COSTS, EXPENSES, OR DAMAGES. WHERE A LIMITATION OF LIABILITY IS NOT ALLOWED IN FULL OR IN PART, THIS LIMITATION MAY NOT APPLY TO YOU. c. The disclaimer of warranties and limitation of liability provided above shall be interpreted in a manner that, to the extent possible, most closely approximates an absolute disclaimer and waiver of all liability. Section 6 -- Term and Termination. a. This Public License applies for the term of the Copyright and Similar Rights licensed here. However, if You fail to comply with this Public License, then Your rights under this Public License terminate automatically. b. Where Your right to use the Licensed Material has terminated under Section 6(a), it reinstates: 1. automatically as of the date the violation is cured, provided it is cured within 30 days of Your discovery of the violation; or 2. upon express reinstatement by the Licensor. For the avoidance of doubt, this Section 6(b) does not affect any right the Licensor may have to seek remedies for Your violations of this Public License. c. For the avoidance of doubt, the Licensor may also offer the Licensed Material under separate terms or conditions or stop distributing the Licensed Material at any time; however, doing so will not terminate this Public License. d. Sections 1, 5, 6, 7, and 8 survive termination of this Public License. Section 7 -- Other Terms and Conditions. a. The Licensor shall not be bound by any additional or different terms or conditions communicated by You unless expressly agreed. b. Any arrangements, understandings, or agreements regarding the Licensed Material not stated herein are separate from and independent of the terms and conditions of this Public License. Section 8 -- Interpretation. a. For the avoidance of doubt, this Public License does not, and shall not be interpreted to, reduce, limit, restrict, or impose conditions on any use of the Licensed Material that could lawfully be made without permission under this Public License. b. To the extent possible, if any provision of this Public License is deemed unenforceable, it shall be automatically reformed to the minimum extent necessary to make it enforceable. If the provision cannot be reformed, it shall be severed from this Public License without affecting the enforceability of the remaining terms and conditions. c. No term or condition of this Public License will be waived and no failure to comply consented to unless expressly agreed to by the Licensor. d. Nothing in this Public License constitutes or may be interpreted as a limitation upon, or waiver of, any privileges and immunities that apply to the Licensor or You, including from the legal processes of any jurisdiction or authority. ======================================================================= Creative Commons is not a party to its public licenses. Notwithstanding, Creative Commons may elect to apply one of its public licenses to material it publishes and in those instances will be considered the “Licensor.” The text of the Creative Commons public licenses is dedicated to the public domain under the CC0 Public Domain Dedication. Except for the limited purpose of indicating that material is shared under a Creative Commons public license or as otherwise permitted by the Creative Commons policies published at creativecommons.org/policies, Creative Commons does not authorize the use of the trademark "Creative Commons" or any other trademark or logo of Creative Commons without its prior written consent including, without limitation, in connection with any unauthorized modifications to any of its public licenses or any other arrangements, understandings, or agreements concerning use of licensed material. For the avoidance of doubt, this paragraph does not form part of the public licenses. Creative Commons may be contacted at creativecommons.org. ================================================ FILE: LICENSE-CODE ================================================ The MIT License (MIT) Copyright (c) Microsoft Corporation Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. ================================================ FILE: README.md ================================================ # Blazor Docs The Blazor docs have moved to the https://github.com/aspnet/AspNetCore.Docs repo and are published at https://docs.microsoft.com/en-us/aspnet/core/blazor. For an overview of the many projects being worked on by the Blazor community page check out the [Awesome Blazor](https://github.com/AdrienTorris/awesome-blazor) page. ================================================ FILE: ThirdPartyNotices ================================================ ##Legal Notices Microsoft and any contributors grant you a license to the Microsoft documentation and other content in this repository under the [Creative Commons Attribution 4.0 International Public License](https://creativecommons.org/licenses/by/4.0/legalcode), see the [LICENSE](LICENSE) file, and grant you a license to any code in the repository under the [MIT License](https://opensource.org/licenses/MIT), see the [LICENSE-CODE](LICENSE-CODE) file. Microsoft, Windows, Microsoft Azure and/or other Microsoft products and services referenced in the documentation may be either trademarks or registered trademarks of Microsoft in the United States and/or other countries. The licenses for this project do not grant you rights to use any Microsoft names, logos, or trademarks. Microsoft's general trademark guidelines can be found at http://go.microsoft.com/fwlink/?LinkID=254653. Privacy information can be found at https://privacy.microsoft.com/en-us/ Microsoft and any contributors reserve all others rights, whether under their respective copyrights, patents, or trademarks, whether by implication, estoppel or otherwise. ================================================ FILE: api/.gitignore ================================================ ############### # temp file # ############### *.yml ================================================ FILE: api/index.md ================================================ --- title: Blazor API description: Find information on the Blazor API. uid: api --- # Blazor API [!INCLUDE[](~/includes/razor-components-preview-notice.md)] Welcome to the Blazor API area! ## Namespaces Use the namespace links in the Table of Contents. ================================================ FILE: appveyor.yml ================================================ skip_tags: true image: Visual Studio 2017 clone_depth: 1 branches: only: - live install: - cinst docfx --version 2.40.7 build_script: - docfx deploy_script: - git config --global credential.helper store - ps: Add-Content "$env:USERPROFILE\.git-credentials" "https://$($env:GITHUB_ACCESS_TOKEN):x-oauth-basic@github.com`n" - git config --global user.email %GITHUB_EMAIL% - git config --global user.name "Blazor doc agent" - bash releaseDocs.sh ================================================ FILE: community.md ================================================ # Blazor community resources [!INCLUDE[](~/includes/razor-components-preview-notice.md)] Below is a list of projects and resources from the Blazor community (links in each section are alphabetical). If you know about a Blazor project that isn't listed, please let us know. We're happy to add it to the list. ## Libraries * [BlazorBits](http://blazorbits.net) ([GitHub repo](https://github.com/blazorbits)) – Components including [Monaco editor](https://github.com/Microsoft/monaco-editor). * [BlazorComponents](https://github.com/muqeet-khan/BlazorComponents) – A demonstration of [Chart.js](https://github.com/chartjs/Chart.js) interop. * [BlazorConfirm](https://github.com/ctrl-alt-d/BlazorConfirm) ([Demo](https://ctrl-alt-d.github.io/BlazorConfirm/)) – A Blazor wrapper for JavaScript's `window.confirm()` and `onbeforeunload`. * [BlazorContextMenu](https://github.com/stavroskasidis/BlazorContextMenu) – A context menu for blazor. * [BlazorDB](https://github.com/chanan/BlazorDB) – In-memory, persisted to local storage, database for Blazor. * [Blazored.LocalStorage](https://github.com/blazored/LocalStorage) – A library to provide access to local storage in Blazor apps. * [Blazored.Menu](https://github.com/Blazored/Menu) – A JavaScript-free menu library for Blazor and Razor Components apps. * [Blazored.Modal](https://github.com/Blazored/Modal) – A JavaScript free modal library for Blazor and Razor Components applications. * [Blazored.Toast](https://github.com/Blazored/Toast) – A JavaScript free toast library for Blazor and Razor Component applications. * [Blazored.Localisation](https://github.com/Blazored/Localisation) – A library to provide localisation in client-side Blazor applications. * [BlazorEmbedLibrary](https://github.com/SQL-MisterMagoo/BlazorEmbedLibrary) – Provides Blazor-style embedded resources to Razor Components projects. * [BlazorWebSocketHelper](https://github.com/Lupusa87/BlazorWebSocketHelper) – A WebSocket library for Blazor. * [BlazorGrid](https://github.com/AnkitSharma-007/BlazorGrid) – Reusable grid component for Blazor, which also supports client side pagination. * [Blazorise](https://github.com/stsrki/Blazorise) ([Demo](https://bootstrapdemo.blazorise.com/)) – Components library for Blazor with support for Bootstrap, Bulma, and Material CSS. * [BlazorMaterial](https://github.com/BlazorExtensions/BlazorMaterial) – Blazor components implementing Google's Material components for web ([Material Design: Web](https://material.io/components/web)). * [BlazorNodaTimeDateTimePicker](https://github.com/nheath99/BlazorNodaTimeDateTimePicker) – A date picker using NodaTime. * [Blazorous](https://github.com/chanan/Blazorous) – Maintainable CSS with Blazor. * [BlazorScrollbar](https://github.com/Lupusa87/BlazorScrollbar) ([Demo](https://lupblazorscrollbar.z20.web.core.windows.net/)) – Reusable, fully configurable component with vertical and horizontal scrollbars. * [BlazorSignalR](https://github.com/csnewman/BlazorSignalR) – ASP.NET Core SignalR .NET client support for Blazor. * [BlazorSplit](https://github.com/BlazorComponents/BlazorSplit) ([Demo](https://blazorcomponents.github.io/BlazorSplit/)) – Resizeable split views. * [BlazorSplitter](https://github.com/Lupusa87/BlazorSplitter) ([Demo](https://lupblazorsplitter.z20.web.core.windows.net/)) – Reusable, fully configurable component with vertical and horizontal splitters and diagonal resizer. * [BlazorStorage](https://github.com/cloudcrate/BlazorStorage) – Blazor local and session storage support. * [BlazorStrap](https://github.com/chanan/BlazorStrap) – Bootstrap 4 Components for Blazor. * [BlazorTodos](https://lupblazortodo.z20.web.core.windows.net/) – Blazor todos demo app with registration, jwt authentication, email reminders and more, backed with Azure Storage Tables. * [BlazorVirtualGrid](https://github.com/Lupusa87/BlazorVirtualGrid) ([Demo](https://lupblazorvirtualgrid.z13.web.core.windows.net/)) – Reusable, fully configurable component with rows and columns fast virtualization. * [Blazor Barcode](https://barcoderesource.com/blazorbarcode.shtml) – A barcode library for Blazor using barcode fonts. * [Blazor Charts](https://github.com/Misfits-Rebels-Outcasts/Blazor-Charts) – SVG Charts for Blazor. * [Blazor Extensions Home](https://github.com/BlazorExtensions/Home) – Home for Blazor Extensions. * [Blazor Fluxor](https://mrpmorris.github.io/blazor-fluxor/) – Flux/Redux library. * [Blazor Gamepad](https://github.com/jsakamoto/Toolbelt.Blazor.Gamepad) – A library to provide gamepad API access for Blazor. * [Blazor Hotkeys](https://github.com/jsakamoto/Toolbelt.Blazor.Hotkeys) – A library to provide configuration-centric keyboard shortcuts for Blazor. * [Blazor LoadingBar](https://github.com/jsakamoto/Toolbelt.Blazor.LoadingBar) – A Blazor port of [angular-loading-bar](https://github.com/chieffancypants/angular-loading-bar). * [Blazor LocalFiles](https://github.com/jburman/W8lessLabs.Blazor.LocalFiles) – Open files in your browser and load into Blazor. * [Blazor Realm](https://dworthen.github.io/BlazorRealm/docs/quickstart.html) – Redux state management with middleware support. * [Blazor Redux](https://github.com/torhovland/blazor-redux) – This library offers Redux-style state management for Blazor. * [Blazor SpeechSynthesis](https://github.com/jsakamoto/Toolbelt.Blazor.SpeechSynthesis) – A library to provide Speech Synthesis API access for Blazor. * [Blazor SVG Helper](https://github.com/Lupusa87/BlazorSvgHelper) ([Demo](https://lupblazordemos.z13.web.core.windows.net)) – Create SVG elements with children (circle, rectangle, image, text, and others) and render with RenderTreeBuilder. * [Blazor Time Zone Kit](https://github.com/jsakamoto/Toolbelt.Blazor.TimeZoneKit) – A library to provide system time zones and local time zone initialization in Blazor apps. * [Blazor Tweet Button](https://github.com/jsakamoto/Toolbelt.Blazor.TwitterShareButton) – A Tweet Button component for Blazor. * [Blazor.Extensions.OfficeUIFabric](https://github.com/BlazorExtensions/Blazor.Extensions.OfficeUIFabric) – Microsoft Office Fabric UI port for Blazor. * [Blazor.FlexGrid](https://github.com/Mewriick/Blazor.FlexGrid) – GridView component for Blazor. * [Blazor.Payments](https://github.com/philipblaquiere/Blazor.Payments) – A library that replicates the [W3C Payment Request API](https://w3c.github.io/payment-request/) contracts in Blazor apps. * [Blazor.Polyfill](https://github.com/Daddoon/Blazor.Polyfill) – A Blazor compatibility library for Internet Explorer 11 and other browsers. * [Blazor.Xamarin](https://github.com/Daddoon/Blazor.Xamarin) – Host Blazor apps as standalone hybrid mobile apps with Xamarin. * [Blazor-State](https://timewarpengineering.github.io/blazor-state/) – Blazor-State is a client side pipeline architecture utilizing MediatR with plugin behaviors. * [Canvas](https://github.com/BlazorExtensions/Canvas) – HTML5 Canvas API implementation for Microsoft Blazor. * [ChartJs.Blazor](https://github.com/mariusmuntean/ChartJs.Blazor) – Blazor Component that wraps ChartJS. * [DevExpress Blazor UI Components](https://github.com/DevExpress/RazorComponents) – UI components including Data Grid, Pivot Grid, and several data editors. * [Elmah.Io.Blazor](https://github.com/elmahio/Elmah.Io.Blazor) – Logs from Blazor to [elmah.io](https://elmah.io/) using Microsoft.Extensions.Logging. * [Logging](https://github.com/BlazorExtensions/Logging) – Microsoft Extension Logging implementation for Blazor. * [MatBlazor](https://github.com/BlazorComponents/MatBlazor) ([Demo](https://blazorcomponents.github.io/MatBlazor/)) – Google Material components for web in Blazor. * [NObservable](https://github.com/kekekeks/NObservable) – MobX-like observables and component instrumentation. * [Notifications](https://github.com/BlazorExtensions/Notifications) – HTML5 Notifications API implementation for Microsoft Blazor. * [SignalR](https://github.com/BlazorExtensions/SignalR) – SignalR Core support for Microsoft ASP.NET Core Blazor. * [Sotsera.Blazor.Toaster](https://github.com/sotsera/sotsera.blazor.toaster) ([Demo](https://sotsera.github.io/sotsera.blazor.toaster/)) – A Blazor port of [Toastr.js](https://github.com/CodeSeven/toastr/). * [Storage](https://github.com/BlazorExtensions/Storage) – HTML5 Storage API implementation for Microsoft Blazor. * [Syncfusion Blazor UI Components](https://github.com/syncfusion/ej2-aspnet-core-blazor-samples) – A complete library of robust UI components including [Data Grid](https://ej2.syncfusion.com/aspnet-core-razor-components/Grid/DefaultFunctionalities), [Charts](https://ej2.syncfusion.com/aspnet-core-razor-components/Charts/polar), [Scheduler](https://ej2.syncfusion.com/aspnet-core-razor-components/Schedule/TimelineResourceGroup), [Inputs](https://ej2.syncfusion.com/aspnet-core-razor-components/TextBox/DefaultFunctionalities), and various [Editor](https://ej2.syncfusion.com/aspnet-core-razor-components/RichTextEditor/DefaultFunctionalities) components. * [Telerik UI for Blazor](https://www.telerik.com/blazor-ui) – A native set of UI components for Blazor, including grid, charting, and calendar components. * [Toastr](https://github.com/BlazorExtensions/Toastr) – A Blazor port of [Toastr.js](https://github.com/CodeSeven/toastr/). ## Samples and tutorials * [A Nicer Looking Blazor Loading Page](http://lightswitchhelpwebsite.com/Blog/tabid/61/EntryId/4315/A-Nicer-Looking-Blazor-Loading-Page.aspx) – Customize the Blazor loading page using [SpinKit](https://github.com/tobiasahlin/SpinKit). * [ASP.NET Core Master/Detail CRUD](https://code.msdn.microsoft.com/vstudio/ASPNET-Core-Blazor-122b108a) – A master/detail HTML CRUD example with sorting and filtering using Entity Framework and Web API. * [BlazeDown](https://github.com/EdCharbeneau/BlazeDown) ([Demo](http://edcharbeneau.com/BlazeDown/)) – An online markdown editor built with Blazor. * [Blazing Chuck](https://davidpine.net/blog/blazing-chuck/) ([Demo](https://bit.ly/BlazingChuck)) – An example Blazor app that displays random "nerdy" Chuck Norris jokes. * [BlazorPass](https://github.com/ebekker/BlazorPass) – Blazor UI and ASP.NET Core API to manage Active Directory credentials. * [Blazor + Electron sample](https://github.com/aspnet/AspLabs/tree/master/src/ComponentsElectron) – Explore how a Blazor app can be used to build a cross-platform desktop app. * [Blazor + Sitecore](https://github.com/GoranHalvarsson/SitecoreBlazor) ([Blog post](https://visionsincode.wordpress.com/2018/06/30/time-travel-into-the-future-blazor-sitecore-helix/)) – Example of dynamic pages and routes with SiteCore and [Helix](https://helix.sitecore.net/). * [Blazor Admin Dashboard](https://github.com/Misfits-Rebels-Outcasts/Blazor-Dashboard) – An admin dashboard for Blazor. * [Blazor Asteroids](https://github.com/aesalazar/AsteroidsWasm) ([Demo](https://aesalazar.github.io/AsteroidsWasm/)) – The 80's classic video game developed in C# for WinForms/WPF but running Blazor. * [Blazor Bricks](https://www.codeproject.com/Articles/1241210/WebAssembly-with-Blazor) – A bricks game developed with C# and Blazor. * [Blazor Calculator](https://github.com/Lupusa87/BlazorCalculator) ([Demo](https://lupblazordemos.z13.web.core.windows.net/CalculatorPage)) – Simple calculator with history and ability to use previous results in new calculations. * [Blazor Calculator with Expressions](https://github.com/khaledmousa/BlazorCalculator) ([Demo](https://khaledmousa.github.io/)) – A sample numerical expression evaluator in Blazor utilizing an F# library that uses FsLex and FsYacc to parse expressions. * [Blazor Chat sample](https://github.com/conficient/BlazorChatSample) ([Demo](https://blazorchatsample.azurewebsites.net/)) – An app that demonstrates the use of [SignalR](https://docs.microsoft.com/aspnet/core/signalr/) to create a Blazor chat app. * [Blazor Chess](https://github.com/Lupusa87/BlazorChess) ([Demo](https://lupblazordemos.z13.web.core.windows.net/ChessPage)) – An experimental Blazor chess engine. * [Blazor Clock Canvas](https://github.com/Lupusa87/BlazorClockCanvas) ([Demo](https://lupblazordemos.z13.web.core.windows.net/ClockCanvas)) – Complex clock based on Canvas. * [Blazor Clock SVG](https://github.com/Lupusa87/BlazorClockSVG) ([Demo](https://lupblazordemos.z13.web.core.windows.net/)) – Complex clock based on SVG. * [Blazor Contoso University](https://github.com/lohithgn/blazor-contoso-university) – Contoso University recreated in Blazor. * [Blazor Converters](https://github.com/lohithgn/blazor-converters) ([Demo](http://blazorconverters.surge.sh)) – Windows 10 Calc Converters recreated in Blazor. * [Blazor Doughnut Chart](https://github.com/Lupusa87/BlazorDoughnutChartComponent) ([Demo](https://lupblazordemos.z13.web.core.windows.net/DoughnutChartpage)) – Doughnut charting with gradient colors using SVG. * [Blazor Examples](https://github.com/lohithgn/blazor-examples) ([Demo](http://blazorexamples.surge.sh/)) – Knockout JS examples recreated in Blazor. * [Blazor Game Snake](https://github.com/Lupusa87/BlazorGameSnake) ([Demo](https://lupblazordemos.z13.web.core.windows.net/GameSnakePage)) – 2D game snake with customizations, path finding algorithm, and sound effects using SVG. * [Blazor Graph API example](https://github.com/jburman/BlazorGraphExample) ([Demo](https://blazorgraph.z20.web.core.windows.net/)) – A self-contained Blazor app that connects to [Microsoft's Graph API](https://docs.microsoft.com/azure/active-directory/develop/active-directory-graph-api), queries the user's information, and allows the user to browse through their [OneDrive](https://onedrive.live.com/about/). * [Blazor Hacker News Clone](https://github.com/lohithgn/blazor-hackernews-clone) ([Demo](http://blazorhackernews.surge.sh/)) – A Hacker News clone built in Blazor. * [Blazor Loan Calculator](https://github.com/Lupusa87/BlazorLoanCalculator) ([Demo](https://lupblazordemos.z13.web.core.windows.net/LoanCalculatorPage)) – A loan payments calculator developed with Blazor. * [Blazor Paint](https://github.com/Lupusa87/BlazorPaint) ([Demo](https://lupblazordemos.z13.web.core.windows.net/PaintPage)) – Drawing app written in Blazor. * [Blazor Password Pattern](https://github.com/Lupusa87/BlazorPasswordPattern) ([Demo](https://lupblazordemos.z13.web.core.windows.net/PasswordPatternPage)) – Password pattern based on SVG. * [Blazor Performance Chart](https://lupblazordemos.z13.web.core.windows.net/PerformanceChartPage) – Performance Chart based on SVG. * [Blazor RealWorld example app](https://github.com/torhovland/blazor-realworld-example-app) – A full-stack app built with Blazor that includes CRUD operations, authentication, routing, and pagination. * [Blazor RSS Reader](https://github.com/lohithgn/blazor-rss-reader) ([Demo](https://blazorrssreader.surge.sh/)) – RSS Reader using Blazor. * [Blazor Spreadsheet](https://github.com/Lupusa87/BlazorSpreadsheet) ([Demo](https://lupblazordemos.z13.web.core.windows.net/SpreadsheetPage)) – Spreadsheet app developed in Blazor. * [Blazor Sushi](https://github.com/lohithgn/blazor-sushi) ([Demo](https://blazorsushi.surge.sh/)) – Kendo UI Sushi SPA recreated in Blazor. * [Blazor To-Do App](https://github.com/BorowskiKamil/blazor-tasks) – A Blazor app that allows you to create and edit tasks and manage categories of tasks. * [Blazor Tour of Heroes](https://github.com/lohithgn/blazor-tour-of-heroes) – A Blazor implementation of [Angular Tour of Heroes](https://angular.io/tutorial). * [Blazor UWP Sample](https://github.com/pushqrdx/Blazor.Universal) – Use Blazor.Server to build UWP apps. * [BlazorServiceWorker](https://github.com/roboriaan/BlazorServiceWorker) – A client-side Blazor template with service worker caching. * [Blazume](https://github.com/Amine-Smahi/Blazume) – A portfolio/resume template using Blazor. * [Bolero.TodoMVC](https://github.com/fsbolero/TodoMVC) – A TodoMVC clone using Bolero. * [CssBuilder](https://www.nuget.org/packages/BlazorComponentUtilities/) – A clean code approach to conditional CSS classes for Razor components in Blazor. * [Data Driven Layout](https://github.com/hutchcodes/Blazor.DataDrivenLayout) ([Blog post](https://hutchcodes.net/2018/09/data-driven-layout-in-razor-components/)) – Two ways of driving the layout based on data in the page. * [Do](https://github.com/jamie-lord/do) ([Demo](https://do.lord.technology)) – Todo.txt compatible todo app. * [FMRL](https://github.com/ebekker/FMRL) – Ephemeral Message Service. Messages sent are encrypted, securely transferred, and automatically deleted when they are retrieved. * [Money](https://github.com/maraf/Money) ([Demo](https://money.neptuo.com)) – A money manager implemented using CQRS+ES. * [Planning Poker for Azure](https://github.com/duracellko/planningpoker4azure) ([Demo](http://planningpoker.duracellko.net)) – An app to play [Planning Poker™](https://www.planningpoker.com) for distributed teams. The app is implemented using Blazor and shows how to switch between client-side and server-side mode with a configuration change. *Planning Poker* is a registered trademark of [Mountain Goat Software, LLC](https://www.mountaingoatsoftware.com/). * [Toss](https://github.com/RemiBou/Toss.Blazor) – A Twitter-like web app that allows the user to sign in, post a new message (a "toss") with hashtag, and select favorite hashtags for finding messages. * [TreeCRUD](https://github.com/ctrl-alt-d/TreeCrud) – A simple server-side Blazor CRUD app to deal with hierarchical data. The project has a data layer with GraphQL for R (Read) and classical REST for CUD (Create, Update, Delete). * [TrendTv](https://github.com/MattMarked/TrendTv) ([Demo](http://zaptube2.azurewebsites.net/)) – Fetch a video list from YouTube and "zap" in real time between trending videos, filtered by country or category. * [Try F# on WebAssembly](https://github.com/fsbolero/TryFSharpOnWasm) – The F# compiler running in WebAssembly with Bolero. * [Tzaar](https://github.com/paularundel/tzaar) ([Demo](https://tzaar.azurewebsites.net/)) – Implementation of the board game Tzaar with Blazor and SignalR. * [Quiz](https://github.com/Amine-Smahi/BlazorQuiz) – Simple quiz using Blazor. * [Validation Controls using Blazor](https://github.com/hishamco/BlazorValidationControls) – Blog posts: [Part I: Basic Validation Controls](http://www.hishambinateya.com/part1-validation-controls-using-blazor-basic-validation-controls) | [Part II: Custom Validation Controls](http://www.hishambinateya.com/part2-validation-controls-using-blazor-custom-validation-controls) * [WebSocketPage](https://github.com/Lupusa87/BlazorWebSocketHelper) ([Demo](https://lupblazordemos.z13.web.core.windows.net/WebSocketPage)) – WebSocket example for Blazor. ## Tooling * [BlazorFiddle](https://blazorfiddle.com) – Blazor .NET developer playground and code editor in the browser. * [Blazor Minimum Project Templates](https://github.com/jsakamoto/BlazorMinimumTemplates) – A project templates package of Blazor apps without JavaScript and CSS libraries. * [Blazor Snippets Visual Studio Code extension](https://marketplace.visualstudio.com/items?itemName=ScottSauber.blazorsnippets) – A Visual Studio Code extension that offers Blazor and Razor snippets. * [Razor+ Visual Studio Code extension](https://marketplace.visualstudio.com/items?itemName=austincummings.razor-plus) – A Visual Studio Code extension that offers improved Razor support. ## Community documentation * [Awesome Blazor](https://github.com/AdrienTorris/awesome-blazor) – A collection of useful Blazor resources. * [Blazor Bites](https://chrissainty.com/tag/blazor-bites/) – Posts on ASP.NET Core and Blazor subjects. * [Learn Blazor](https://learn-blazor.com/) – Community documentation on Blazor. * [LightSwitch Help Website](https://lightswitchhelpwebsite.com/Blog/tabid/61/tagid/66/Blazor.aspx) – Blogs and code samples primarily covering server-side Blazor (Razor Components). * [WebAssemblyMan](https://www.webassemblyman.com/) – Man page for Blazor and WebAssembly. ## Books * [Blazor Revealed](https://www.apress.com/gp/book/9781484243428) – Build web apps in Microsoft .NET that run in any modern browser, helping you to transfer your .NET experience and skills to a new environment and build browser-based apps using a robust and type-safe language and runtime. * [Blazor Quick Start Guide: Build web applications using Blazor, EF Core, and SQL Server (2018)](https://amzn.to/2OToEji) – An introduction to Blazor core concepts and how to apply concepts to real-world web apps with the help of Entity Framework Core and SQL Server. * [Dockerizing ASP.NET Core and Blazor Applications on Mac](https://www.c-sharpcorner.com/ebooks/dockerizing-asp-net-core-and-blazor-applications-on-mac) – This book is targeted for beginning to intermediate .NET developers who want to jump into ASP.NET Core, Blazor, and Docker on macOS. ## Courses * [Blazor First Look on LinkedIn Learning](https://www.linkedin.com/learning/blazor-first-look) * [Free Blazor Training Course](https://www.devexpress.com/support/training/blazor/) ## Streams and podcasts * [Blazor StateHasChanged: The weekly community live show](https://www.youtube.com/edwardcharbeneau) ## Other * [Bionic](https://bionicframework.github.io/Documentation) – An Ionic CLI clone for Blazor projects. * [Bolero](https://github.com/fsbolero/Bolero) – Blazor for F# with hot reloaded templates, type-safe endpoints and routing, remoting, and much more. ================================================ FILE: docfx.json ================================================ { "metadata": [ { "src": [ { "files": [ "src/**.dll" ] } ], "dest": "api", "disableGitFeatures": false } ], "build": { "content": [ { "files": [ "api/**.yml", "toc.yml", "**/*.md" ], "exclude": [ "**/obj/**", "**/sample/**", "**/samples/**", "**/includes/**", "_site/**" ], "src": "." } ], "resource": [ { "files": [ "**/*.png", "**/*.jpg" ], "exclude": [ "**/obj/**", "**/includes/**", "_site/**" ], "src": "." } ], "overwrite": [], "dest": "_site", "globalMetadataFiles": [], "fileMetadataFiles": [], "template": [ "default", "template" ], "postProcessors": [], "noLangKeyword": false, "keepFileLink": false, "cleanupCacheHistory": false, "disableGitFeatures": false, "globalMetadata": { "_gitContribute": { "branch": "master" } } } } ================================================ FILE: docs/common/samples/3.x/BlazorSample/App.cshtml ================================================  ================================================ FILE: docs/common/samples/3.x/BlazorSample/BlazorSample.csproj ================================================  netstandard2.0 dotnet blazor serve 7.3 ================================================ FILE: docs/common/samples/3.x/BlazorSample/Components/ListViewTemplate.cshtml ================================================ @typeparam TItem @functions { [Parameter] RenderFragment ItemTemplate { get; set; } [Parameter] IReadOnlyList Items { get; set; } } ================================================ FILE: docs/common/samples/3.x/BlazorSample/Components/Tab.cshtml ================================================ @using BlazorSample.UIInterfaces @implements IDisposable @implements ITab
  • @Title
  • @functions { [CascadingParameter] TabSet ContainerTabSet { get; set; } [Parameter] string Title { get; set; } [Parameter] public RenderFragment ChildContent { get; private set; } string TitleCssClass => ContainerTabSet.ActiveTab == this ? "active" : null; protected override void OnInit() { ContainerTabSet.AddTab(this); } public void Dispose() { ContainerTabSet.RemoveTab(this); } void Activate() { ContainerTabSet.SetActivateTab(this); } } ================================================ FILE: docs/common/samples/3.x/BlazorSample/Components/TabSet.cshtml ================================================ @using BlazorSample.UIInterfaces @functions { [Parameter] RenderFragment ChildContent { get; set; } public ITab ActiveTab { get; private set; } public void AddTab(ITab tab) { if (ActiveTab == null) { SetActivateTab(tab); } } public void RemoveTab(ITab tab) { if (ActiveTab == tab) { SetActivateTab(null); } } public void SetActivateTab(ITab tab) { if (ActiveTab != tab) { ActiveTab = tab; StateHasChanged(); } } } ================================================ FILE: docs/common/samples/3.x/BlazorSample/Components/TableTemplate.cshtml ================================================ @typeparam TItem @TableHeader @foreach (var item in Items) { @RowTemplate(item) } @TableFooter
    @functions { [Parameter] RenderFragment TableHeader { get; set; } [Parameter] RenderFragment RowTemplate { get; set; } [Parameter] RenderFragment TableFooter { get; set; } [Parameter] IReadOnlyList Items { get; set; } } ================================================ FILE: docs/common/samples/3.x/BlazorSample/JsInteropClasses/ExampleJsInterop.cs ================================================ using System; using System.Collections.Generic; using System.Linq; using System.Net; using System.Threading.Tasks; using Microsoft.JSInterop; namespace BlazorSample.JsInteropClasses { #region snippet1 public class ExampleJsInterop { public static Task Prompt(string text) { // showPrompt is implemented in wwwroot/exampleJsInterop.js return JSRuntime.Current.InvokeAsync( "exampleJsFunctions.showPrompt", text); } public static Task Display(string welcomeMessage) { // displayWelcome is implemented in wwwroot/exampleJsInterop.js return JSRuntime.Current.InvokeAsync( "exampleJsFunctions.displayWelcome", welcomeMessage); } public static Task CallHelloHelperSayHello(string name) { // sayHello is implemented in wwwroot/exampleJsInterop.js return JSRuntime.Current.InvokeAsync( "exampleJsFunctions.sayHello", new DotNetObjectRef(new HelloHelper(name))); } } #endregion } ================================================ FILE: docs/common/samples/3.x/BlazorSample/JsInteropClasses/HelloHelper.cs ================================================ using System; using System.Collections.Generic; using System.Linq; using System.Threading.Tasks; using Microsoft.JSInterop; namespace BlazorSample.JsInteropClasses { #region snippet1 public class HelloHelper { public HelloHelper(string name) { Name = name; } public string Name { get; set; } [JSInvokable] public string SayHello() => $"Hello, {Name}!"; } #endregion } ================================================ FILE: docs/common/samples/3.x/BlazorSample/Pages/BlazorRocks.cshtml ================================================ @page "/BlazorRocks" @* The inherit directive provides the properties and methods of the BlazorRocksBase class to this component. *@ @inherits BlazorRocksBase

    @BlazorRocksText

    BlazorRocks.cshtml

    The heading content is supplied by a property in the BlazorRocksBase class in another file, BlazorRocksBase.cs. BlazorRocksBase is inherited using the @@inherits BlazorRocksBase directive.

    @@inherits BlazorRocksBase
    
    <h1>@@BlazorRocksText</h1>

    BlazorRocksBase.cs

    using Microsoft.AspNetCore.Blazor.Components;
    
    public class BlazorRocksBase : BlazorComponent
    {
        public string BlazorRocksText { get; set; } = 
            "Blazor rocks the browser!";
    }
    ================================================ FILE: docs/common/samples/3.x/BlazorSample/Pages/BlazorRocksBase.cs ================================================ using Microsoft.AspNetCore.Blazor.Components; public class BlazorRocksBase : BlazorComponent { public string BlazorRocksText { get; set; } = "Blazor rocks the browser!"; } ================================================ FILE: docs/common/samples/3.x/BlazorSample/Pages/BlazorRoute.cshtml ================================================ @page "/BlazorRoute" @page "/DifferentBlazorRoute"

    Blazor routing

    Reach this page component on two routes, /BlazorRoute and /DifferentBlazorRoute.

    The routes are supplied to the component using @@page directives:

    @@page "/BlazorRoute"
    @@page "/DifferentBlazorRoute"
    
    <h1>Blazor routing</h1>
    ================================================ FILE: docs/common/samples/3.x/BlazorSample/Pages/CascadingValuesParametersTabSet.cshtml ================================================ @page "/CascadingValuesParametersTabSet"

    Cascading Values & Parameters - TabSet

    Greetings from the first tab!

    The second tab says Hello World!

    @if (showThirdTab) {

    Welcome to the disappearing third tab!

    Toggle this tab from the first tab.

    }

    ITab.cs

    The ITab interface is implemented by tabs:

    @@using Microsoft.AspNetCore.Blazor;
    
    namespace BlazorSample.UIInterfaces
    {
        public interface ITab
        {
            RenderFragment ChildContent { get; }
        }
    }

    Component

    This component (CascadingValuesParametersTabSet.cshtml) uses the TabSet component, which contains several Tab components:

    <TabSet>
        <Tab Title="First tab">
            <h4>Greetings from the first tab!</h4>
    
            <label>
                <input type="checkbox" bind=@@showThirdTab />
                Toggle third tab
            </label>
        </Tab>
        <Tab Title="Second tab">
            <h4>The second tab says Hello World!</h4>
        </Tab>
    
        @@if (showThirdTab)
        {
            <Tab Title="Third tab">
                <h4>Welcome to the disappearing third tab!</h4>
                <p>Toggle this tab from the first tab.</p>
            </Tab>
        }
    </TabSet>
        
    @@functions
    {
        bool showThirdTab;
    }

    TabSet.csthml

    The child Tab components aren't explicitly passed as parameters to the TabSet. Instead, the child Tab components are part of the child content of the TabSet. However, the TabSet still needs to know about each Tab so that it can render the headers and the active tab. To enable this coordination without requiring additional code, the TabSet component can provide itself as a cascading value that is then picked up by the descendent Tab components.

    @@using BlazorSample.UIInterfaces
    
    <!-- Display the tab headers -->
    <CascadingValue Value=this>
        <ul class="nav nav-tabs">
            @@ChildContent
        </ul>
    </CascadingValue>
    
    <!-- Display body for only the active tab -->
    <div class="nav-tabs-body p-4">
        @@ActiveTab?.ChildContent
    </div>
    
    @@functions {
        [Parameter] RenderFragment ChildContent { get; set; }
    
        public ITab ActiveTab { get; private set; }
    
        public void AddTab(ITab tab)
        {
            if (ActiveTab == null)
            {
                SetActivateTab(tab);
            }
        }
    
        public void RemoveTab(ITab tab)
        {
            if (ActiveTab == tab)
            {
                SetActivateTab(null);
            }
        }
    
        public void SetActivateTab(ITab tab)
        {
            if (ActiveTab != tab)
            {
                ActiveTab = tab;
                StateHasChanged();
            }
        }
    }

    Tab.cshtml

    The descendent Tab components capture the containing TabSet as a cascading parameter, so the Tab components add themselves to the TabSet and coordinate on which Tab is active.

    @@using BlazorSample.UIInterfaces
    @@implements IDisposable
    @@implements ITab
    
    <li>
        <a onclick=@@Activate class="nav-link @@TitleCssClass" role="button">
            @@Title
        </a>
    </li>
    
    @@functions {
        [CascadingParameter] TabSet ContainerTabSet { get; set; }
        [Parameter] string Title { get; set; }
        [Parameter] public RenderFragment ChildContent { get; private set; }
    
        string TitleCssClass => ContainerTabSet.ActiveTab == this ? "active" : null;
    
        protected override void OnInit()
        {
            ContainerTabSet.AddTab(this);
        }
    
        public void Dispose()
        {
            ContainerTabSet.RemoveTab(this);
        }
    
        void Activate()
        {
            ContainerTabSet.SetActivateTab(this);
        }
    }
    @functions { bool showThirdTab; } ================================================ FILE: docs/common/samples/3.x/BlazorSample/Pages/CascadingValuesParametersTheme.cshtml ================================================ @page "/cascadingvaluesparameterstheme" @layout CascadingValuesParametersLayout @using BlazorSample.UIThemeClasses

    Cascading Values & Parameters - Theme

    Current count: @currentCount

    @functions { int currentCount = 0; [CascadingParameter] protected ThemeInfo ThemeInfo { get; set; } void IncrementCount() { currentCount++; } }

    The layout component (CascadingValuesParametersLayout.cshtml) supplies a cascading ThemeInfo object to the components of the Body property that use this layout:

    @@inherits BlazorLayoutComponent
    @@using BlazorSample.UIThemeClasses
    
    <div class="container-fluid">
        <div class="row">
            <div class="col-sm-3">
                <NavMenu />
            </div>
            <div class="col-sm-9">
                <CascadingValue Value="@@theme">
                    <div class="content px-4">
                        @@Body
                    </div>
                </CascadingValue>
            </div>
        </div>
    </div>
    
    @@functions {
        ThemeInfo theme = new ThemeInfo { ButtonClass = "btn-success" };
    }

    This component (CascadingValuesParametersTheme.cshtml) receives the ThemeInfo as a CascadingParameter. The parameter is used to style one of the buttons:

    <button class="btn" onclick="@@IncrementCount">Increment Counter (Unthemed)</button>
    
    <button class="btn @@ThemeInfo.ButtonClass" onclick="@@IncrementCount">Increment Counter (Themed)</button>
    
    @@functions {
        int currentCount = 0;
    
        [CascadingParameter] protected ThemeInfo ThemeInfo { get; set; }
    
        void IncrementCount()
        {
            currentCount++;
        }
    }
    ================================================ FILE: docs/common/samples/3.x/BlazorSample/Pages/ChildComponent.cshtml ================================================
    @Title
    @ChildContent
    @functions { [Parameter] private string Title { get; set; } [Parameter] private RenderFragment ChildContent { get; set; } } ================================================ FILE: docs/common/samples/3.x/BlazorSample/Pages/FetchData.cshtml ================================================ @page "/fetchdata" @page "/fetchdata/{StartDate:datetime}" @inject HttpClient Http

    Weather forecast

    This component demonstrates fetching data from the server.

    @if (forecasts == null) {

    Loading...

    } else { @foreach (var forecast in forecasts) { }
    Date Temp. (C) Temp. (F) Summary
    @forecast.DateFormatted @forecast.TemperatureC @forecast.TemperatureF @forecast.Summary

    ◀ Previous Next ▶

    } @functions { [Parameter] DateTime StartDate { get; set; } WeatherForecast[] forecasts; public override void SetParameters(ParameterCollection parameters) { StartDate = DateTime.Now; base.SetParameters(parameters); } protected override async Task OnParametersSetAsync() { forecasts = await Http.GetJsonAsync( $"sample-data/weather.json?date={StartDate.ToString("yyyy-MM-dd")}"); // Because StandaloneApp doesn't really have a server endpoint to get dynamic data from, // fake the DateFormatted values here. This would not apply in a real app. for (var i = 0; i < forecasts.Length; i++) { forecasts[i].DateFormatted = StartDate.AddDays(i).ToShortDateString(); } } class WeatherForecast { public string DateFormatted { get; set; } public int TemperatureC { get; set; } public int TemperatureF { get; set; } public string Summary { get; set; } } } ================================================ FILE: docs/common/samples/3.x/BlazorSample/Pages/HeadingComponent.cshtml ================================================ @using System.Globalization @* The 'using' directive makes System.Globalization available to the component. System.Globalization provides a method for converting a string into title case (capitalizes the first letter of every word in a string), which is used to convert a a string into title case for a heading. *@ @* Heading text is rendered by evaluating the _headingText field. The font-style of the heading is rendered by evaluating the _headingFontStyle field. *@

    @_headingText

    @* A check box sets the font style and is bound to the _italicsCheck field. *@
    @* When the form is submitted, the onclick event executes the UpdateHeading method. *@
    @functions { private static TextInfo _tinfo = CultureInfo.CurrentCulture.TextInfo; private string _headingText = _tinfo.ToTitleCase("welcome to blazor!"); private string _headingFontStyle = "normal"; private bool _italicsCheck = false; // When UpdateHeading is executed, _italicsCheck determines // the value of _headingFontStyle to set the font style of the // heading. public void UpdateHeading() { _headingFontStyle = _italicsCheck ? "italic" : "normal"; } } ================================================ FILE: docs/common/samples/3.x/BlazorSample/Pages/Index.cshtml ================================================ @page "/" @* The page directive indicates this component is available as a page at the root of the app, the "/" route. *@ @* Razor components can be nested. HeadingComponent is a component supplied by the Razor file HeadingComponent.cshtml. *@

    Index.cshtml

    HeadingComponent (HeadingComponent.cshtml) is embedded within this Index page component:

    <HeadingComponent />

    HeadingComponent.cshtml

    @@System.Globalization
    @@*
        The 'using' directive makes System.Globalization available to
        the component.
    *@@
    
    @@*
        Heading text is rendered by evaluating the _headingText field.
        The font-style of the heading is rendered by evaluating the
        _headingFontStyle field.
    *@@
    <h1 style="font-style:@@_headingFontStyle">@@_headingText</h1>
    
    <form>
        <div class="form-check">
            @@*
                A check box sets the font style and is bound to the _italicsCheck field.
            *@@
            <input type="checkbox" class="form-check-input" id="italicsCheck" bind="@@_italicsCheck" />
            <label class="form-check-label" for="italicsCheck">Use italics</label>
        </div>
    
        @@*
            When the form is submitted, the onclick event executes
            the UpdateHeading method.
        *@@
        <button type="button" class="btn btn-primary" onclick="@@UpdateHeading">
            Update heading
        </button>
    </form>
    
    @@functions {
        private static TextInfo _tinfo = CultureInfo.CurrentCulture.TextInfo;
        private string _headingText = _tinfo.ToTitleCase("welcome to blazor!");
        private string _headingFontStyle = "normal";
        private bool _italicsCheck = false;
    
        // When UpdateHeading is executed, _italicsCheck determines
        // the value of _headingFontStyle to set the font style of the
        // heading.
        public void UpdateHeading()
        {
            _headingFontStyle = _italicsCheck ? "italic" : "normal";
        }
    }
    ================================================ FILE: docs/common/samples/3.x/BlazorSample/Pages/JSInterop.cshtml ================================================ @page "/JSInterop" @using BlazorSample.JsInteropClasses @using Microsoft.JSInterop;

    JavaScript Interop

    Invoke JavaScript functions from .NET methods

    @functions { public async void TriggerJsPrompt() { var name = await ExampleJsInterop.Prompt("What's your name?"); await ExampleJsInterop.Display($"Hello {name}! Welcome to Blazor!"); } }

    When TriggerJsPrompt is executed by selecting the component's Trigger JavaScript Prompt button, the ExampleJsInterop.Prompt method in C# code is called.

    The Prompt method executes the JavaScript showPrompt function provided in the wwwroot/exampleJsInterop.js file.

    The showPrompt function accepts user input (the user's name), which is HTML-encoded and returned to the Prompt method and ultimately back to the component. The component stores the user's name in a local variable, name.

    The string stored in name is incorporated into a welcome message, which is passed to a second C# method, ExampleJsInterop.Display.

    Display calls a JavaScript function, displayWelcome, which renders the welcome message into a heading tag.

    Invoke .NET methods from JavaScript functions

    Examine the console output in your broswer's developer tools when selecting the following buttons to trigger .NET static and instance methods.

    When the button to call the C# static method is selected, the JavaScript returnArrayAsyncJs function in wwwroot/exampleJsInterop.js is executed. The function uses DotNet.invokeMethodAsync to call the C# static method ReturnArrayAsync. The C# method returns an integer array to the JavaScript function, which writes the array to the console.

    When the button to call the C# instance method is selected, ExampleJsInterop.CallHelloHelperSayHello is called and passes a name to the method. ExampleJsInterop.CallHelloHelperSayHello invokes the JavaScript function sayHello with a new instance of HelloHelper. The name is passed to HelloHelper's constructor, which sets the HelloHelper.Name property. When the JavaScript function sayHello is executed, HelloHelper.SayHello returns the Hello, {Name}! message, which is written to the console.

    @functions { [JSInvokable] public static Task ReturnArrayAsync() { return Task.FromResult(new int[] { 1, 2, 3 }); } } @functions { public async void TriggerNetInstanceMethod() { await ExampleJsInterop.CallHelloHelperSayHello("Blazor"); } } ================================================ FILE: docs/common/samples/3.x/BlazorSample/Pages/ParentComponent.cshtml ================================================ @page "/ParentComponent"

    Parent-child example

    Child content of the child component is supplied by the parent component.

    ParentComponent (ParentComponent.cshtml; this page) embeds a child component into the page using the <ChildComponent> tag. The child component (ChildComponent.cshtml) contains a Bootstrap-styled panel.

    The Title attribute and panel content are specified by the <ChildComponent> element. The Title attribute is a component parameter.

    ParentComponent.cshtml

    <ChildComponent Title="Panel Title from Parent">
        Child content of the child component is supplied by the parent component.
    </ChildComponent>

    ChildComponent.cshtml

    <div class="panel panel-success">
        <div class="panel-heading">@@Title</div>
        <div class="panel-body">@@ChildContent</div>
    </div>
    
    @@functions {
        [Parameter]
        private string Title { get; set; }
    
        [Parameter]
        private RenderFragment ChildContent { get; set; }
    }
    ================================================ FILE: docs/common/samples/3.x/BlazorSample/Pages/RazorTemplates.cshtml ================================================ @page "/RazorTemplates"

    Razor Templates

    Render fragments can be defined using Razor template syntax. Razor templates are a way to define a UI snippet.

    @@{
        RenderFragment template = @@<p>The time is @DateTime.Now.</p>;
        RenderFragment<Pet> petTemplate = (pet) => @@<p>Your pet's name is @@pet.Name.</p>;
    }
    
    @{ RenderFragment template = @

    The time is @DateTime.Now.

    ; RenderFragment petTemplate = (pet) => @

    Your pet's name is @pet.Name.

    ; }

    Render fragments defined using Razor templates can be passed as arguments to templated components or rendered directly. For example, the previous templates are directly rendered with the following Razor markup:

    @@template
    
    @@petTemplate(new Pet { Name = "Rex" })
    @template @petTemplate(new Pet { Name = "Rex" }) @functions { List pets = new List { new Pet { PetId = 1, Name = "Rin Tin Tin" }, new Pet { PetId = 2, Name = "Mr. Bigglesworth" }, new Pet { PetId = 3, Name = "Fred" }, new Pet { PetId = 4, Name = "Salem Saberhagen" }, new Pet { PetId = 5, Name = "Lassie" }, new Pet { PetId = 6, Name = "Spot" }, new Pet { PetId = 7, Name = "K-9" } }; class Pet { public int PetId { get; set; } public string Name { get; set; } } } ================================================ FILE: docs/common/samples/3.x/BlazorSample/Pages/RouteParameter.cshtml ================================================ @page "/RouteParameter" @page "/RouteParameter/{text}"

    Blazor is @Text!

    @functions { [Parameter] private string Text { get; set; } = "fantastic"; }

    RouteParameter.cshtml

    Request this page with a route parameter, and the parameter is included in the heading. The Blazor client-side router uses route parameters to populate the corresponding component parameters.

    @@page "/RouteParameter"
    @@page "/RouteParameter/{Text}"
    
    <h1>Blazor is @@Text!</h1>
    
    @@functions {
        [Parameter]
        private string Text { get; set; } = "fantastic";
    }

    Example:

    /RouteParameter/amazing
    Renders HTML:
    <h1>Blazor is amazing!</h1>

    ================================================ FILE: docs/common/samples/3.x/BlazorSample/Pages/TemplatedComponents.cshtml ================================================ @page "/TemplatedComponents"

    Templated Components

    Templated components are components that accept one or more UI templates as parameters, which can then be used as part of the component's rendering logic. Templated components allow you to author higher-level components that are more reusable than regular components.

    The following table template examples use the template defined in Components/TableTemplate.cshtml.

    Implicit template parameters

    Component arguments of type RenderFragment<T> passed as elements have an implicit parameter named context.

    <TableTemplate Items="@@pets">
        <TableHeader>
            <th>ID</th>
            <th>Name</th>
        </TableHeader>
        <RowTemplate>
            <td>@@context.PetId</td>
            <td>@@context.Name</td>
        </RowTemplate>
    </TableTemplate>
    ID Name @context.PetId @context.Name

    Explicit template parameters

    You can change the template parameter name using the Context attribute on the child element.

    <TableTemplate Items="@@pets">
        <TableHeader>
            <th>ID</th>
            <th>Name</th>
            <th>TV Show/Movie</th>
        </TableHeader>
        <RowTemplate Context="pet">
            <td>@@pet.PetId</td>
            <td>@@pet.Name</td>
        </RowTemplate>
    </TableTemplate>
    ID Name @pet.PetId @pet.Name

    Generic-typed Components

    Templated components are often generically typed. For example, a generic ListView component can be used to render IEnumerable<T> values. To define a generic component, use the @@typeparam directive to specify type parameters.

    The following ListView template examples use the template defined in Components/ListViewTemplate.cshtml.

    Inferred type:

    <ListViewTemplate Items="@@pets">
        <ItemTemplate Context="pet">
            <li>@@pet.Name</li>
        </ItemTemplate>
    </ListViewTemplate>
  • @pet.Name
  • Explicitly typed (TItem="Pet"):

    <ListViewTemplate Items="@@pets" TItem="Pet">
        <ItemTemplate Context="pet">
            <li>@@pet.Name</li>
        </ItemTemplate>
    </ListViewTemplate>
  • @pet.Name
  • @functions { List pets = new List { new Pet { PetId = 1, Name = "Rin Tin Tin" }, new Pet { PetId = 2, Name = "Mr. Bigglesworth" }, new Pet { PetId = 3, Name = "Fred" }, new Pet { PetId = 4, Name = "Salem Saberhagen" }, new Pet { PetId = 5, Name = "Lassie" }, new Pet { PetId = 6, Name = "Spot" }, new Pet { PetId = 7, Name = "K-9" } }; class Pet { public int PetId { get; set; } public string Name { get; set; } } } ================================================ FILE: docs/common/samples/3.x/BlazorSample/Pages/_ViewImports.cshtml ================================================ @layout MainLayout ================================================ FILE: docs/common/samples/3.x/BlazorSample/Program.cs ================================================ using Microsoft.AspNetCore.Blazor.Hosting; namespace BlazorSample { public class Program { public static void Main(string[] args) { CreateHostBuilder(args).Build().Run(); } public static IWebAssemblyHostBuilder CreateHostBuilder(string[] args) => BlazorWebAssemblyHost.CreateDefaultBuilder() .UseBlazorStartup(); } } ================================================ FILE: docs/common/samples/3.x/BlazorSample/README.md ================================================ # Blazor Sample This sample illustrates the use of Blazor scenarios described in the Blazor documentation. ================================================ FILE: docs/common/samples/3.x/BlazorSample/Shared/CascadingValuesParametersLayout.cshtml ================================================ @inherits BlazorLayoutComponent @using BlazorSample.UIThemeClasses
    @Body
    @functions { ThemeInfo theme = new ThemeInfo { ButtonClass = "btn-success" }; } ================================================ FILE: docs/common/samples/3.x/BlazorSample/Shared/MainLayout.cshtml ================================================ @inherits BlazorLayoutComponent
    @Body
    ================================================ FILE: docs/common/samples/3.x/BlazorSample/Shared/NavMenu.cshtml ================================================  ================================================ FILE: docs/common/samples/3.x/BlazorSample/Startup.cs ================================================ using BlazorSample; using Microsoft.AspNetCore.Blazor.Builder; using Microsoft.Extensions.DependencyInjection; public class Startup { public void ConfigureServices(IServiceCollection services) { } public void Configure(IBlazorApplicationBuilder app) { app.AddComponent("app"); } } ================================================ FILE: docs/common/samples/3.x/BlazorSample/UIInterfaces/ITab.cs ================================================ using Microsoft.AspNetCore.Blazor; namespace BlazorSample.UIInterfaces { public interface ITab { RenderFragment ChildContent { get; } } } ================================================ FILE: docs/common/samples/3.x/BlazorSample/UIThemeClasses/ThemeInfo.cs ================================================ using System; using System.Collections.Generic; using System.Linq; using System.Threading.Tasks; namespace BlazorSample.UIThemeClasses { public class ThemeInfo { public string ButtonClass { get; set; } } } ================================================ FILE: docs/common/samples/3.x/BlazorSample/_ViewImports.cshtml ================================================ @using System.Net.Http @using Microsoft.AspNetCore.Blazor @using Microsoft.AspNetCore.Blazor.Components @using Microsoft.AspNetCore.Blazor.Layouts @using Microsoft.AspNetCore.Blazor.Routing @using BlazorSample @using BlazorSample.Shared ================================================ FILE: docs/common/samples/3.x/BlazorSample/wwwroot/css/site.css ================================================ .main-nav li .glyphicon { margin-right: 10px; } /* Highlighting rules for nav menu items */ .main-nav li a.active, .main-nav li a.active:hover, .main-nav li a.active:focus { background-color: #4189C7; color: white; } /* Keep the nav menu independent of scrolling and on top of other items */ .main-nav { position: fixed; top: 0; left: 0; right: 0; z-index: 1; } p, .panel { margin-top: 15px } /* Styles for the TabSet/Tabs */ .nav-tabs .nav-link { border-color: #dee2e6 #dee2e6 #fff; border-bottom-color: #dee2e6; background-color: #f9f9f9; } .nav-tabs .active { border-top: 4px solid #e0108b !important; padding-top: 5px; border-bottom: 1px solid transparent; background-color: white; } .nav-tabs > li { margin-bottom: -1px; } .nav-tabs-body { border: 1px solid #dee2e6; border-top-width: 0; padding: 15px; } @media (max-width: 767px) { /* On small screens, the nav menu spans the full width of the screen. Leave a space for it. */ body { padding-top: 50px; } } @media (min-width: 768px) { /* On small screens, convert the nav menu to a vertical sidebar */ .main-nav { height: 100%; width: calc(25% - 20px); } .main-nav .navbar { border-radius: 0px; border-width: 0px; height: 100%; } .main-nav .navbar-header { float: none; } .main-nav .navbar-collapse { border-top: 1px solid #444; padding: 0px; } .main-nav .navbar ul { float: none; } .main-nav .navbar li { float: none; font-size: 15px; margin: 6px; } .main-nav .navbar li a { padding: 10px 16px; border-radius: 4px; } .main-nav .navbar a { /* If a menu item's text is too long, truncate it */ width: 100%; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; } } /* Temporary workaround due to the wrapper element. The wrapper element will be eliminated in a future update, making this workaround unnecessary. */ .navbar-nav > li a { color: #9d9d9d; line-height: 20px; position: relative; display: block; } .navbar-nav > li a:hover { color: #fff; background-color: transparent; text-decoration: none; } .navbar-nav > li a:focus { text-decoration: none; } .alert-survey { color: #6a6969; background-color: #e8e8e8; border-color: #d3d3d3; margin-top: 25px; } .alert-survey a { font-weight: bold; } ================================================ FILE: docs/common/samples/3.x/BlazorSample/wwwroot/exampleJsInterop.js ================================================ window.exampleJsFunctions = { showPrompt: function (text) { return prompt(text, 'Type your name here'); }, displayWelcome: function (welcomeMessage) { document.getElementById('welcome').innerText = welcomeMessage; }, returnArrayAsyncJs: function () { DotNet.invokeMethodAsync('BlazorSample', 'ReturnArrayAsync') .then(data => { data.push(4); console.log(data); }) }, sayHello: function (dotnetHelper) { return dotnetHelper.invokeMethodAsync('SayHello') .then(r => console.log(r)); } }; ================================================ FILE: docs/common/samples/3.x/BlazorSample/wwwroot/index.html ================================================  Blazor Sample Loading... ================================================ FILE: docs/common/samples/3.x/BlazorSample/wwwroot/sample-data/weather.json ================================================ [ { "dateFormatted": "06/05/2018", "temperatureC": 1, "summary": "Freezing", "temperatureF": 33 }, { "dateFormatted": "07/05/2018", "temperatureC": 14, "summary": "Bracing", "temperatureF": 57 }, { "dateFormatted": "08/05/2018", "temperatureC": -13, "summary": "Freezing", "temperatureF": 9 }, { "dateFormatted": "09/05/2018", "temperatureC": -16, "summary": "Balmy", "temperatureF": 4 }, { "dateFormatted": "10/05/2018", "temperatureC": -2, "summary": "Chilly", "temperatureF": 29 } ] ================================================ FILE: docs/component-libraries.md ================================================ ================================================ FILE: docs/components/index.md ================================================ ================================================ FILE: docs/debugging.md ================================================ ================================================ FILE: docs/dependency-injection.md ================================================ ================================================ FILE: docs/get-started.md ================================================ ================================================ FILE: docs/host-and-deploy/configure-linker.md ================================================ ================================================ FILE: docs/host-and-deploy/index.md ================================================ ================================================ FILE: docs/hosting-models/samples_snapshot/Startup.cs ================================================ public class Startup { public void ConfigureServices(IServiceCollection services) { services.AddServerSideBlazor(); services.AddResponseCompression(options => { options.MimeTypes = ResponseCompressionDefaults.MimeTypes.Concat(new[] { MediaTypeNames.Application.Octet, WasmMediaTypeNames.Application.Wasm, }); }); } public void Configure(IApplicationBuilder app, IHostingEnvironment env) { app.UseResponseCompression(); if (env.IsDevelopment()) { app.UseDeveloperExceptionPage(); } // Use component registrations and static files from the app project. app.UseServerSideBlazor(); } } ================================================ FILE: docs/hosting-models.md ================================================ ================================================ FILE: docs/index.md ================================================ ================================================ FILE: docs/introduction/faq.md ================================================ ================================================ FILE: docs/introduction/index.md ================================================ ================================================ FILE: docs/javascript-interop.md ================================================ ================================================ FILE: docs/layouts.md ================================================ ================================================ FILE: docs/routing.md ================================================ ================================================ FILE: docs/toc.md ================================================ # [Get started](xref:razor-components/get-started) # [Build your first app](xref:razor-components/tutorials/first-app) # [Introduction](xref:razor-components/introduction/index) # [Components](xref:razor-components/components/index) # [Component libraries](xref:razor-components/component-libraries) # [Layouts](xref:razor-components/layouts) # [Dependency injection](xref:razor-components/dependency-injection) # [Routing](xref:razor-components/routing) # [JavaScript interop](xref:razor-components/javascript-interop) # [Debugging](xref:razor-components/debugging) # [Hosting models](xref:razor-components/hosting-models) # [Host and deploy](xref:razor-components/host-and-deploy/index) ## [Configure the Linker](xref:razor-components/host-and-deploy/configure-linker) # [FAQ](xref:razor-components/introduction/faq) ================================================ FILE: docs/tutorials/build-your-first-blazor-app/samples/3.x/BlazorApp1/App.cshtml ================================================  ================================================ FILE: docs/tutorials/build-your-first-blazor-app/samples/3.x/BlazorApp1/BlazorApp1.csproj ================================================  netstandard2.0 dotnet blazor serve 7.3 ================================================ FILE: docs/tutorials/build-your-first-blazor-app/samples/3.x/BlazorApp1/Pages/Counter.cshtml ================================================ @page "/counter"

    Counter!!

    Current count: @currentCount

    @functions { int currentCount = 0; [Parameter] private int IncrementAmount { get; set; } = 1; void IncrementCount() { currentCount+=IncrementAmount; } } ================================================ FILE: docs/tutorials/build-your-first-blazor-app/samples/3.x/BlazorApp1/Pages/FetchData.cshtml ================================================ @page "/fetchdata" @inject HttpClient Http

    Weather forecast

    This component demonstrates fetching data from the server.

    @if (forecasts == null) {

    Loading...

    } else { @foreach (var forecast in forecasts) { }
    Date Temp. (C) Temp. (F) Summary
    @forecast.Date.ToShortDateString() @forecast.TemperatureC @forecast.TemperatureF @forecast.Summary
    } @functions { WeatherForecast[] forecasts; protected override async Task OnInitAsync() { forecasts = await Http.GetJsonAsync("sample-data/weather.json"); } class WeatherForecast { public DateTime Date { get; set; } public int TemperatureC { get; set; } public int TemperatureF { get; set; } public string Summary { get; set; } } } ================================================ FILE: docs/tutorials/build-your-first-blazor-app/samples/3.x/BlazorApp1/Pages/Index.cshtml ================================================ @page "/"

    Hello, world!

    Welcome to your new app. ================================================ FILE: docs/tutorials/build-your-first-blazor-app/samples/3.x/BlazorApp1/Pages/ToDo.cshtml ================================================ @page "/todo"

    Todo (@todos.Where(todo => !todo.IsDone).Count())

      @foreach (var todo in todos) {
    • }
    @functions { IList todos = new List(); string newTodo; void AddTodo() { if (!string.IsNullOrWhiteSpace(newTodo)) { todos.Add(new TodoItem { Title = newTodo }); newTodo = string.Empty; } } } ================================================ FILE: docs/tutorials/build-your-first-blazor-app/samples/3.x/BlazorApp1/Pages/_ViewImports.cshtml ================================================ @layout MainLayout ================================================ FILE: docs/tutorials/build-your-first-blazor-app/samples/3.x/BlazorApp1/Program.cs ================================================ using Microsoft.AspNetCore.Blazor.Hosting; namespace BlazorApp1 { public class Program { public static void Main(string[] args) { CreateHostBuilder(args).Build().Run(); } public static IWebAssemblyHostBuilder CreateHostBuilder(string[] args) => BlazorWebAssemblyHost.CreateDefaultBuilder() .UseBlazorStartup(); } } ================================================ FILE: docs/tutorials/build-your-first-blazor-app/samples/3.x/BlazorApp1/README.md ================================================ # Build Your First Blazor App Sample (BlazorApp1) This sample illustrates the basic features of the Blazor app development framework. ================================================ FILE: docs/tutorials/build-your-first-blazor-app/samples/3.x/BlazorApp1/Shared/MainLayout.cshtml ================================================ @inherits BlazorLayoutComponent
    @Body
    ================================================ FILE: docs/tutorials/build-your-first-blazor-app/samples/3.x/BlazorApp1/Shared/NavMenu.cshtml ================================================ 
    @functions { bool collapseNavMenu = true; void ToggleNavMenu() { collapseNavMenu = !collapseNavMenu; } } ================================================ FILE: docs/tutorials/build-your-first-blazor-app/samples/3.x/BlazorApp1/Shared/SurveyPrompt.cshtml ================================================  @functions { [Parameter] string Title { get; set; } // Demonstrates how a parent component can supply parameters } ================================================ FILE: docs/tutorials/build-your-first-blazor-app/samples/3.x/BlazorApp1/Startup.cs ================================================ using Microsoft.AspNetCore.Blazor.Builder; using Microsoft.Extensions.DependencyInjection; namespace BlazorApp1 { public class Startup { public void ConfigureServices(IServiceCollection services) { } public void Configure(IBlazorApplicationBuilder app) { app.AddComponent("app"); } } } ================================================ FILE: docs/tutorials/build-your-first-blazor-app/samples/3.x/BlazorApp1/TodoItem.cs ================================================ public class TodoItem { public string Title { get; set; } public bool IsDone { get; set; } } ================================================ FILE: docs/tutorials/build-your-first-blazor-app/samples/3.x/BlazorApp1/_ViewImports.cshtml ================================================ @using System.Net.Http @using Microsoft.AspNetCore.Blazor.Layouts @using Microsoft.AspNetCore.Blazor.Routing @using Microsoft.JSInterop @using BlazorApp1 @using BlazorApp1.Shared ================================================ FILE: docs/tutorials/build-your-first-blazor-app/samples/3.x/BlazorApp1/wwwroot/css/open-iconic/FONT-LICENSE ================================================ SIL OPEN FONT LICENSE Version 1.1 Copyright (c) 2014 Waybury PREAMBLE The goals of the Open Font License (OFL) are to stimulate worldwide development of collaborative font projects, to support the font creation efforts of academic and linguistic communities, and to provide a free and open framework in which fonts may be shared and improved in partnership with others. The OFL allows the licensed fonts to be used, studied, modified and redistributed freely as long as they are not sold by themselves. The fonts, including any derivative works, can be bundled, embedded, redistributed and/or sold with any software provided that any reserved names are not used by derivative works. The fonts and derivatives, however, cannot be released under any other type of license. The requirement for fonts to remain under this license does not apply to any document created using the fonts or their derivatives. DEFINITIONS "Font Software" refers to the set of files released by the Copyright Holder(s) under this license and clearly marked as such. This may include source files, build scripts and documentation. "Reserved Font Name" refers to any names specified as such after the copyright statement(s). "Original Version" refers to the collection of Font Software components as distributed by the Copyright Holder(s). "Modified Version" refers to any derivative made by adding to, deleting, or substituting -- in part or in whole -- any of the components of the Original Version, by changing formats or by porting the Font Software to a new environment. "Author" refers to any designer, engineer, programmer, technical writer or other person who contributed to the Font Software. PERMISSION & CONDITIONS Permission is hereby granted, free of charge, to any person obtaining a copy of the Font Software, to use, study, copy, merge, embed, modify, redistribute, and sell modified and unmodified copies of the Font Software, subject to the following conditions: 1) Neither the Font Software nor any of its individual components, in Original or Modified Versions, may be sold by itself. 2) Original or Modified Versions of the Font Software may be bundled, redistributed and/or sold with any software, provided that each copy contains the above copyright notice and this license. These can be included either as stand-alone text files, human-readable headers or in the appropriate machine-readable metadata fields within text or binary files as long as those fields can be easily viewed by the user. 3) No Modified Version of the Font Software may use the Reserved Font Name(s) unless explicit written permission is granted by the corresponding Copyright Holder. This restriction only applies to the primary font name as presented to the users. 4) The name(s) of the Copyright Holder(s) or the Author(s) of the Font Software shall not be used to promote, endorse or advertise any Modified Version, except to acknowledge the contribution(s) of the Copyright Holder(s) and the Author(s) or with their explicit written permission. 5) The Font Software, modified or unmodified, in part or in whole, must be distributed entirely under this license, and must not be distributed under any other license. The requirement for fonts to remain under this license does not apply to any document created using the Font Software. TERMINATION This license becomes null and void if any of the above conditions are not met. DISCLAIMER THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM OTHER DEALINGS IN THE FONT SOFTWARE. ================================================ FILE: docs/tutorials/build-your-first-blazor-app/samples/3.x/BlazorApp1/wwwroot/css/open-iconic/ICON-LICENSE ================================================ The MIT License (MIT) Copyright (c) 2014 Waybury Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. ================================================ FILE: docs/tutorials/build-your-first-blazor-app/samples/3.x/BlazorApp1/wwwroot/css/open-iconic/README.md ================================================ [Open Iconic v1.1.1](http://useiconic.com/open) =========== ### Open Iconic is the open source sibling of [Iconic](http://useiconic.com). It is a hyper-legible collection of 223 icons with a tiny footprint—ready to use with Bootstrap and Foundation. [View the collection](http://useiconic.com/open#icons) ## What's in Open Iconic? * 223 icons designed to be legible down to 8 pixels * Super-light SVG files - 61.8 for the entire set * SVG sprite—the modern replacement for icon fonts * Webfont (EOT, OTF, SVG, TTF, WOFF), PNG and WebP formats * Webfont stylesheets (including versions for Bootstrap and Foundation) in CSS, LESS, SCSS and Stylus formats * PNG and WebP raster images in 8px, 16px, 24px, 32px, 48px and 64px. ## Getting Started #### For code samples and everything else you need to get started with Open Iconic, check out our [Icons](http://useiconic.com/open#icons) and [Reference](http://useiconic.com/open#reference) sections. ### General Usage #### Using Open Iconic's SVGs We like SVGs and we think they're the way to display icons on the web. Since Open Iconic are just basic SVGs, we suggest you display them like you would any other image (don't forget the `alt` attribute). ``` icon name ``` #### Using Open Iconic's SVG Sprite Open Iconic also comes in a SVG sprite which allows you to display all the icons in the set with a single request. It's like an icon font, without being a hack. Adding an icon from an SVG sprite is a little different than what you're used to, but it's still a piece of cake. *Tip: To make your icons easily style able, we suggest adding a general class to the* `` *tag and a unique class name for each different icon in the* `` *tag.* ``` ``` Sizing icons only needs basic CSS. All the icons are in a square format, so just set the `` tag with equal width and height dimensions. ``` .icon { width: 16px; height: 16px; } ``` Coloring icons is even easier. All you need to do is set the `fill` rule on the `` tag. ``` .icon-account-login { fill: #f00; } ``` To learn more about SVG Sprites, read [Chris Coyier's guide](http://css-tricks.com/svg-sprites-use-better-icon-fonts/). #### Using Open Iconic's Icon Font... ##### …with Bootstrap You can find our Bootstrap stylesheets in `font/css/open-iconic-bootstrap.{css, less, scss, styl}` ``` ``` ``` ``` ##### …with Foundation You can find our Foundation stylesheets in `font/css/open-iconic-foundation.{css, less, scss, styl}` ``` ``` ``` ``` ##### …on its own You can find our default stylesheets in `font/css/open-iconic.{css, less, scss, styl}` ``` ``` ``` ``` ## License ### Icons All code (including SVG markup) is under the [MIT License](http://opensource.org/licenses/MIT). ### Fonts All fonts are under the [SIL Licensed](http://scripts.sil.org/cms/scripts/page.php?item_id=OFL_web). ================================================ FILE: docs/tutorials/build-your-first-blazor-app/samples/3.x/BlazorApp1/wwwroot/css/site.css ================================================ @import url('open-iconic/font/css/open-iconic-bootstrap.min.css'); html, body { font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif; } app { position: relative; display: flex; flex-direction: column; } .top-row { height: 3.5rem; display: flex; align-items: center; } .main { flex: 1; } .main .top-row { background-color: #e6e6e6; border-bottom: 1px solid #d6d5d5; } .sidebar { background-image: linear-gradient(180deg, rgb(5, 39, 103) 0%, #3a0647 70%); } .sidebar .top-row { background-color: rgba(0,0,0,0.4); } .sidebar .navbar-brand { font-size: 1.1rem; } .sidebar .oi { width: 2rem; font-size: 1.1rem; vertical-align: text-top; top: -2px; } .nav-item { font-size: 0.9rem; padding-bottom: 0.5rem; } .nav-item:first-of-type { padding-top: 1rem; } .nav-item:last-of-type { padding-bottom: 1rem; } .nav-item a { color: #d7d7d7; border-radius: 4px; height: 3rem; display: flex; align-items: center; line-height: 3rem; } .nav-item a.active { background-color: rgba(255,255,255,0.25); color: white; } .nav-item a:hover { background-color: rgba(255,255,255,0.1); color: white; } .content { padding-top: 1.1rem; } .navbar-toggler { background-color: rgba(255, 255, 255, 0.1); } @media (max-width: 767.98px) { .main .top-row { display: none; } } @media (min-width: 768px) { app { flex-direction: row; } .sidebar { width: 250px; height: 100vh; position: sticky; top: 0; } .main .top-row { position: sticky; top: 0; } .main > div { padding-left: 2rem !important; padding-right: 1.5rem !important; } .navbar-toggler { display: none; } .sidebar .collapse { /* Never collapse the sidebar for wide screens */ display: block; } } ================================================ FILE: docs/tutorials/build-your-first-blazor-app/samples/3.x/BlazorApp1/wwwroot/index.html ================================================ BlazorApp1 Loading... ================================================ FILE: docs/tutorials/build-your-first-blazor-app/samples/3.x/BlazorApp1/wwwroot/sample-data/weather.json ================================================ [ { "date": "2018-05-06", "temperatureC": 1, "summary": "Freezing", "temperatureF": 33 }, { "date": "2018-05-07", "temperatureC": 14, "summary": "Bracing", "temperatureF": 57 }, { "date": "2018-05-08", "temperatureC": -13, "summary": "Freezing", "temperatureF": 9 }, { "date": "2018-05-09", "temperatureC": -16, "summary": "Balmy", "temperatureF": 4 }, { "date": "2018-05-10", "temperatureC": -2, "summary": "Chilly", "temperatureF": 29 } ] ================================================ FILE: docs/tutorials/build-your-first-blazor-app.md ================================================ ================================================ FILE: includes/razor-components-preview-notice.md ================================================ > [!NOTE] > ASP.NET Core Razor Components is supported in ASP.NET Core 3.0 or later. > > Blazor is an unsupported experimental web framework that shouldn't be used for production workloads at this time. ================================================ FILE: index.md ================================================ --- title: Welcome to the Blazor preview docs website! description: Learn about Blazor, an experimental .NET web framework using C#/Razor and HTML that runs in the browser with WebAssembly. documentType: index ---

    Blazor

    Full-stack web development with C# and WebAssembly

    Build a Web UI with C#

    Blazor is an experimental .NET web framework using C# and HTML that runs in the browser.

    Full-stack .NET

    Do full-stack .NET development using stable and consistent tools, languages, and APIs both in the browser and on the server.

    Runs in all browsers and implements .NET Standard

    Blazor runs in all browsers on the real .NET runtime with full support for .NET Standard. Blazor requires no plugins and no code transpilation, only open web standards.

    Native performance with WebAssembly

    Blazor runs on WebAssembly, giving you native performance in the browser and a trusted security sandbox.

    Native browser apps

    Easily interact with your existing JavaScript code, your favorite libraries, and any browser API through JavaScript interop.

    Simple and productive

    Get started fast and remain productive with project templates, great tooling, and reusable components.

    Get involved

    Join the community that's building Blazor, writing documentation, building samples, and more!

    Open-source & free

    Blazor is part of the open-source .NET platform that has a strong community of over 25,000 contributors from over 1,700 companies.

    ================================================ FILE: releaseDocs.sh ================================================ #!/bin/sh set -e export VSINSTALLDIR="C:\Program Files (x86)\Microsoft Visual Studio\2017\Community" export VisualStudioVersion="15.0" SOURCE_DIR=$PWD TEMP_REPO_DIR=$PWD/../blazor-gh-pages echo "Removing temporary doc directory $TEMP_REPO_DIR" rm -rf $TEMP_REPO_DIR mkdir $TEMP_REPO_DIR echo "Cloning the repo with the gh-pages branch" git clone https://github.com/aspnet/Blazor.Docs.git --branch gh-pages $TEMP_REPO_DIR echo "Clear repo directory" cd $TEMP_REPO_DIR git rm -r * echo "Copy documentation into the repo" cp -r $SOURCE_DIR/_site/* . cp $SOURCE_DIR/CNAME . echo "Push the new docs to the remote branch" git add . -A git commit -m "Update generated documentation" git push origin gh-pages ================================================ FILE: src/Microsoft.AspNetCore.Blazor.Browser.xml ================================================ Microsoft.AspNetCore.Blazor.Browser Provides extension methods for . Associates the component type with the application, causing it to be displayed in the specified DOM element. The . The type of the component. A CSS selector that uniquely identifies a DOM element. A builder for constructing a Blazor application. Gets the application services. Associates the with the application, causing it to be displayed in the specified DOM element. The type of the component. A CSS selector that uniquely identifies a DOM element. Used to to create instances a Blazor host builder for a Browser application. Creates a an instance of . The . A program abstraction. The programs configured services. Start the program. Used to abort program start. Attempts to gracefully stop the program. Used to indicate when stop should no longer be graceful. Abstraction for configuring a Blazor browser-based application. A central location for sharing state between components during the host building process. Adds services to the container. This can be called multiple times and the results will be additive. The delegate for configuring the that will be used to construct the . The same instance of the for chaining. Run the given actions to initialize the host. This can only be called once. An initialized A central location for sharing state between components during the host building process. Adds services to the container. This can be called multiple times and the results will be additive. The same instance of the for chaining. Run the given actions to initialize the host. This can only be called once. An initialized Context containing the common services on the . Some properties may be null until set by the . Creates a new . The property collection. A central location for sharing state between components during the host building process. Provides Blazor-specific support for . Adds services to the container. This can be called multiple times and the results will be additive. The to configure. The same instance of the for chaining. Configures the to use the provided startup class. The . A type that configures a Blazor application. The . Configures the to use the provided startup class. A type that configures a Blazor application. The . The . Extension methods for . Runs the application. The to run. Currently, Blazor applications running in the browser don't have a lifecycle - the application does not get a chance to gracefully shut down. For now, simply starts the host and allows execution to continue. A browser-compatible implementation of Gets or sets the default value of the 'credentials' option on outbound HTTP requests. Defaults to . The name of a well-known property that can be added to to control the arguments passed to the underlying JavaScript fetch API. Specifies a value for the 'credentials' option on outbound HTTP requests. Advises the browser never to send credentials (such as cookies or HTTP auth headers). Advises the browser to send credentials (such as cookies or HTTP auth headers) only if the target URL is on the same origin as the calling application. Advises the browser to send credentials (such as cookies or HTTP auth headers) even for cross-origin requests. Provides mechanisms for rendering instances in a web browser, dispatching events to them, and refreshing the UI as required. Constructs an instance of . Constructs an instance of . The to use when initializing components. Attaches a new root component to the renderer, causing it to be displayed in the specified DOM element. The type of the component. A CSS selector that uniquely identifies a DOM element. Associates the with the , causing it to be displayed in the specified DOM element. The type of the component. A CSS selector that uniquely identifies a DOM element. Disposes the instance. Provides mechanisms for dispatching events to components in a . This is marked 'internal' because it only gets invoked from JS code. For framework use only. For framework use only. For framework use only. For framework use only. For framework use only. For framework use only. Temporary mechanism for registering the Mono JS runtime. Developers do not need to use this directly, and it will be removed shortly. Temporary mechanism for registering the Mono JS runtime. Developers do not need to use this directly, and it will be removed shortly. The return value is intended to be used with GC.KeepAlive purely as a way of ensuring the invocation doesn't get stripped out by the linker (if it's smart enough to do so). An implementation of configured with default services suitable for use in a browser environment. Constructs an instance of . Constructs an instance of . A callback that can be used to configure the . Default browser implementation of . Gets the instance of . Called to initialize BaseURI and current URI before those values the first time. Override this method to dynamically calculate the those values. For framework use only. Given the document's document.baseURI value, returns the URI that can be prepended to relative URI paths to produce an absolute URI. This is computed by removing anything after the final slash. Internal for tests. The page's document.baseURI value. The URI prefix Framework infrastructure, not intended to be used by application code. Framework infrastructure, not intended to be used by application code. Framework infrastructure, not intended by used by application code. Framework infrastructure, not intended by used by application code. Framework infrastructure, not intended by used by application code. Framework infrastructure, not intended by used by application code. ================================================ FILE: src/Microsoft.AspNetCore.Blazor.Server.xml ================================================ Microsoft.AspNetCore.Blazor.Server Provides configuration options to the middleware. Full path to the client assembly. Provides extension methods that add Blazor-related middleware to the ASP.NET pipeline. Configures the middleware pipeline to work with Blazor. Any type from the client app project. This is used to identify the client app assembly. The . The . Configures the middleware pipeline to work with Blazor. The . Options to configure the middleware. The . Extension methods to configure an for Server-Side Blazor. These are just shorthand for combining UseSignalR with UseBlazor. Registers Server-Side Blazor in the pipeline. The . A Blazor startup type. The . Registers Server-Side Blazor in the pipeline. The . A instance used to configure the Blazor file provider. The . Represents a mechanism for rebuilding a .NET project. For example, it could be a way of signalling to a VS process to perform a build. Finds the VS process that launched this app process (if any), and uses named pipes to communicate with its AutoRebuild listener (if any). A SignalR hub that accepts connections to a Server-Side Blazor app. Intended for framework use only. Applications should not instantiate this class directly. Gets the default endpoint path for incoming connections. Intended for framework use only. Applications should not call this method directly. Intended for framework use only. Applications should not call this method directly. Intended for framework use only. Applications should not call this method directly. Intended for framework use only. Applications should not call this method directly. Behaves like a , but automatically times out the underlying task after a given period if not already completed. Represents an active connection between a Blazor server and a client. Gets the current . Gets the associated with this circuit. Gets the associated with this circuit. Gets the current , if any. Sets the current . The . Calling will store the circuit and other related values such as the and in the local execution context. Application code should not need to call this method, it is primarily used by the Server-Side Blazor infrastructure. Provides Stream APIs for writing to a MessagePack-supplied expandable buffer. A Server-Side Blazor implementation of . Creates a new . Initializes the . The absolute URI of the current page. The absolute base URI of the current page. For framework use only. Navigates to the specified URI. The destination URI. This can be absolute, or relative to the base URI (as returned by ). A MessagePack IFormatterResolver that provides an efficient binary serialization of . The client-side code knows how to walk through this binary representation directly, without it first being parsed as an object graph. Provides a custom binary serializer for instances. This is designed with both server-side and client-side perf in mind: * Array-like regions always have a fixed size per entry (even if some entry types don't require as much space as others) so the recipient can index directly. * The indices describing where field data starts, where each string value starts, etc., are written *after* that data, so when writing the data we don't have to compute the locations up front or seek back to an earlier point in the stream. The recipient can only process the data after reading it all into a buffer, so it's no disadvantage for the location info to be at the end. * We only serialize the data that the JS side will need. For example, we don't emit frame sequence numbers, or any representation of nonstring attribute values, or component instances, etc. We don't have or need a .NET reader for this format. We only read it from JS code. Contains values for WASM-related media types. Contains values for WASM-related media types within the "application." namespace The standard media type name for WebAssembly binary files. Notifies when a rendering exception occured. Creates a new . The . The . The . The . A that can be used to serialize renderer operations. Attaches a new root component to the renderer, causing it to be displayed in the specified DOM element. The type of the component. A CSS selector that uniquely identifies a DOM element. Associates the with the , causing it to be displayed in the specified DOM element. The type of the component. A CSS selector that uniquely identifies a DOM element. Disposes the instance. Represents an exception related to remote rendering. Constructs an instance of . The exception message. Extension methods to configure an for Server-Side Blazor. Adds Server-Side Blazor services to the service collection. The . The . Adds Server-Side Blazor services to the service collection. The . A Blazor startup type. The . Adds Server-Side Blazor services to the service collection. The . A Blazor startup type. The . ================================================ FILE: src/Microsoft.AspNetCore.Blazor.xml ================================================ Microsoft.AspNetCore.Blazor Infrastructure for the discovery of bind attributes for markup elements. To extend the set of bind attributes, define a public class named BindAttributes and annotate it with the appropriate attributes. Configures options for binding specific element types. Constructs an instance of . The tag name of the element. The suffix value. For example, set this to value for bind-value, or set this to null for bind. The name of the value attribute to be bound. The name of an attribute that will register an associated change event. Gets the tag name of the element. Gets the suffix value. For example, this will be value to mean bind-value, or null to mean bind. Gets the name of the value attribute to be bound. Gets the name of an attribute that will register an associated change event. Configures options for binding subtypes of an HTML input element. Constructs an instance of . The value of the element's type attribute. The suffix value. The name of the value attribute to be bound. The name of an attribute that will register an associated change event. Gets the value of the element's type attribute. Gets the suffix value. Gets the name of the value attribute to be bound. Gets the name of an attribute that will register an associated change event. Methods used internally by @bind syntax. Not intended to be used directly. Not intended to be used directly. Not intended to be used directly. Not intended to be used directly. Not intended to be used directly. Not intended to be used directly. Not intended to be used directly. Not intended to be used directly. Not intended to be used directly. Not intended to be used directly. Not intended to be used directly. Not intended to be used directly. Not intended to be used directly. Not intended to be used directly. Not intended to be used directly. Not intended to be used directly. Not intended to be used directly. Not intended to be used directly. Optional base class for Blazor components. Alternatively, Blazor components may implement directly. Specifies the name of the -building method. Constructs an instance of . Renders the component to the supplied . A that will receive the render output. Method invoked when the component is ready to start, having received its initial parameters from its parent in the render tree. Method invoked when the component is ready to start, having received its initial parameters from its parent in the render tree. Override this method if you will perform an asynchronous operation and want the component to refresh when that operation is completed. A representing any asynchronous operation. Method invoked when the component has received parameters from its parent in the render tree, and the incoming values have been assigned to properties. Method invoked when the component has received parameters from its parent in the render tree, and the incoming values have been assigned to properties. A representing any asynchronous operation. Notifies the component that its state has changed. When applicable, this will cause the component to be re-rendered. Returns a flag to indicate whether the component should render. Method invoked after each time the component has been rendered. Method invoked after each time the component has been rendered. Note that the component does not automatically re-render after the completion of any returned , because that would cause an infinite render loop. A representing any asynchronous operation. Method invoked to apply initial or updated parameters to the component. The parameters to apply. Denotes the target member as a cascading component parameter. Its value will be supplied by the closest ancestor component that supplies values with a compatible type and name. If specified, the parameter value will be supplied by the closest ancestor that supplies a value with this name. If null, the parameter value will be supplied by the closest ancestor that supplies a value with a compatible type. A component that provides a cascading value to all descendant components. The content to which the value should be provided. The value to be provided. Optionally gives a name to the provided value. Descendant components will be able to receive the value by specifying this name. If no name is specified, then descendant components will receive the value based the type of value they are requesting. If true, indicates that will not change. This is a performance optimization that allows the framework to skip setting up change notifications. Set this flag only if you will not change during the component's lifetime. Resolves components for an application. Lists all the types Associates an event argument type with an event attribute name. Constructs an instance of . Gets the attribute name. Gets the event argument type. A bound event handler delegate. Creates the new . The delegate to bind. Invokes the delegate associated with this binding. The . Holds attributes to configure the mappings between event names and event argument types. Represents a UI component. Initializes the component. A that allows the component to be rendered. Sets parameters supplied by the component's parent in the render tree. The parameters. Interface implemented by components that receive notification that they have been rendered. Notifies the component that it has been rendered. Interface implemented by components that receive notification of their events. Notifies the component that one of its event handlers has been triggered. The event binding. Arguments for the event handler. Indicates that the associated property should have a value injected from the service provider during initialization. Represents a single parameter supplied to an by its parent in the render tree. Gets the name of the parameter. Gets the value being supplied for the parameter. Gets a value to indicate whether the parameter is cascading, meaning that it was supplied by a . Denotes the target member as a component parameter. Represents a collection of parameters supplied to an by its parent in the render tree. Gets an empty . Returns an enumerator that iterates through the . The enumerator. Gets the value of the parameter with the specified name. The type of the value. The name of the parameter. Receives the result, if any. True if a matching parameter was found; false otherwise. Gets the value of the parameter with the specified name, or a default value if no such parameter exists in the collection. The type of the value. The name of the parameter. The parameter value if found; otherwise the default value for the specified type. Gets the value of the parameter with the specified name, or a specified default value if no such parameter exists in the collection. The type of the value. The name of the parameter. The default value to return if no such parameter exists in the collection. The parameter value if found; otherwise . Returns a dictionary populated with the contents of the . A dictionary populated with the contents of the . Extension methods for the type. Iterates through the , assigning each parameter to a property of the same name on . The . An object that has a public writable property matching each parameter's name and type. An enumerator that iterates through a . Gets the current value of the enumerator. Instructs the enumerator to move to the next value in the sequence. A flag to indicate whether or not there is a next value. Allows a component to notify the renderer that it should be rendered. Gets a value that indicates whether the has been initialised and is ready to use. Notifies the renderer that the component should be rendered. The content that should be rendered. Indicates that the associated component should match the specified route template pattern. Constructs an instance of . The route template. Gets the route template. Used by generated code produced by the Blazor code generator. Not intended or supported for use in application code. Not intended for use by application code. Represents a reference to a rendered element. Extension methods for working with JSON APIs. Sends a GET request to the specified URI, and parses the JSON response body to create an object of the generic type. A type into which the response body can be JSON-deserialized. The . The URI that the request will be sent to. The response parsed as an object of the generic type. Sends a POST request to the specified URI, including the specified in JSON-encoded format, and parses the JSON response body to create an object of the generic type. The . The URI that the request will be sent to. Content for the request body. This will be JSON-encoded and sent as a string. The response parsed as an object of the generic type. Sends a POST request to the specified URI, including the specified in JSON-encoded format, and parses the JSON response body to create an object of the generic type. A type into which the response body can be JSON-deserialized. The . The URI that the request will be sent to. Content for the request body. This will be JSON-encoded and sent as a string. The response parsed as an object of the generic type. Sends a PUT request to the specified URI, including the specified in JSON-encoded format. The . The URI that the request will be sent to. Content for the request body. This will be JSON-encoded and sent as a string. Sends a PUT request to the specified URI, including the specified in JSON-encoded format, and parses the JSON response body to create an object of the generic type. A type into which the response body can be JSON-deserialized. The . The URI that the request will be sent to. Content for the request body. This will be JSON-encoded and sent as a string. The response parsed as an object of the generic type. Sends an HTTP request to the specified URI, including the specified in JSON-encoded format. The . The HTTP method. The URI that the request will be sent to. Content for the request body. This will be JSON-encoded and sent as a string. Sends an HTTP request to the specified URI, including the specified in JSON-encoded format, and parses the JSON response body to create an object of the generic type. A type into which the response body can be JSON-deserialized. The . The HTTP method. The URI that the request will be sent to. Content for the request body. This will be JSON-encoded and sent as a string. The response parsed as an object of the generic type. Provides mechanisms for converting between .NET objects and JSON strings. Serializes the value as a JSON string. The value to serialize. The JSON string. Deserializes the JSON string, creating an object of the specified generic type. The type of object to create. The JSON string. An object of the specified type. Optional base class for components that represent a layout. Alternatively, Blazor components may implement directly and declare their own parameter named . Gets the content to be rendered inside the layout. Indicates that the associated component type uses a specified layout. The type of the layout. The type myst implement and must accept a parameter with the name 'Body'. Constructs an instance of . The type of the layout. Displays the specified page component, rendering it inside its layout and any further nested layouts. Gets or sets the type of the page component to display. The type must implement . Gets or sets the parameters to pass to the page. A string value that can be rendered as markup such as HTML. Constructs an instance of . The value for the new instance. Gets the value of the . Casts a to a . The value. Represents a segment of UI content, implemented as a delegate that writes the content to a . The to which the content should be written. Represents a segment of UI content for an object of type , implemented as a function that returns a . The type of object. The value used to build the content. Tracks the rendering state associated with an instance within the context of a . This is an internal implementation detail of . Constructs an instance of . The with which the new instance should be associated. The externally visible identifier for the . The identifier must be unique in the context of the . The whose state is being tracked. The for the parent component, or null if this is a root component. Describes a set of UI changes. Gets the changes to components that were added or updated. Gets render frames that may be referenced by entries in . For example, edit entries of type will point to an entry in this array to specify the subtree to be prepended. Gets the IDs of the components that were disposed. Gets the IDs of the event handlers that were disposed. Collects the data produced by the rendering system during the course of rendering a single batch. This tracks both the final output data and the intermediate states (such as the queue of components still to be rendered). Provides mechanisms for rendering hierarchies of instances, dispatching events to them, and notifying when the user interface is being updated. Constructs an instance of . The to be used when initialising components. Constructs a new component of the specified type. The type of the component to instantiate. The component instance. Associates the with the , assigning an identifier that is unique within the scope of the . The component. The component's assigned identifier. Performs the first render for a root component. After this, the root component makes its own decisions about when to re-render, so there is no need to call this more than once. The ID returned by . Updates the visible UI. The changes to the UI since the previous call. A to represent the UI update process. Notifies the specified component that an event has occurred. The unique identifier for the component within the scope of this . The value from the original event attribute. Arguments to be passed to the event handler. Schedules a render for the specified . Its display will be populated using the specified . The ID of the component to render. A that will supply the updated UI contents. Implements a list that uses an array of objects to store the elements. This differs from a in that it not only grows as required but also shrinks if cleared with significant excess capacity. This makes it useful for component rendering, because components can be long-lived and re-render frequently, with the rendered size varying dramatically depending on the user's navigation in the app. Constructs a new instance of . Constructs a new instance of . Gets the number of items. Gets the underlying buffer. Appends a new item, automatically resizing the underlying array if necessary. The item to append. The index of the appended item. Sets the supplied value at the specified index. The index must be within range for the array. The index. The value. Removes the last item. Marks the array as empty, also shrinking the underlying storage if it was not being used to near its full capacity. Produces an structure describing the current contents. The . Produces an structure describing the selected contents. The index of the first item in the segment. One plus the index of the last item in the segment. The . Represents a range of elements in an array that are in use. The array item type. Gets the underlying array instance. Gets the number of items in the array that are considered to be in use. Constructs an instance of . The array. The number of items in the array that are in use. Creates a shallow clone of the instance. Provides methods for building a collection of entries. The reserved parameter name used for supplying child content. Constructs an instance of . The associated . Appends a frame representing an element, i.e., a container for other frames. In order for the state to be valid, you must also call immediately after appending the new element's child frames. An integer that represents the position of the instruction in the source code. A value representing the type of the element. Marks a previously appended element frame as closed. Calls to this method must be balanced with calls to . Appends a frame representing markup content. An integer that represents the position of the instruction in the source code. Content for the new markup frame. Appends a frame representing text content. An integer that represents the position of the instruction in the source code. Content for the new text frame. Appends frames representing an arbitrary fragment of content. An integer that represents the position of the instruction in the source code. Content to append. Appends frames representing an arbitrary fragment of content. An integer that represents the position of the instruction in the source code. Content to append. The value used by . Appends a frame representing markup content. An integer that represents the position of the instruction in the source code. Content for the new markup frame. Appends a frame representing text content. An integer that represents the position of the instruction in the source code. Content for the new text frame. Appends a frame representing a bool-valued attribute. The attribute is associated with the most recently added element. If the value is false and the current element is not a component, the frame will be omitted. An integer that represents the position of the instruction in the source code. The name of the attribute. The value of the attribute. Appends a frame representing a string-valued attribute. The attribute is associated with the most recently added element. If the value is null and the current element is not a component, the frame will be omitted. An integer that represents the position of the instruction in the source code. The name of the attribute. The value of the attribute. Appends a frame representing an -valued attribute. The attribute is associated with the most recently added element. If the value is null and the current element is not a component, the frame will be omitted. An integer that represents the position of the instruction in the source code. The name of the attribute. The value of the attribute. Appends a frame representing an -valued attribute. The attribute is associated with the most recently added element. If the value is null and the current element is not a component, the frame will be omitted. An integer that represents the position of the instruction in the source code. The name of the attribute. The value of the attribute. Appends a frame representing a -valued attribute. The attribute is associated with the most recently added element. If the value is null and the current element is not a component, the frame will be omitted. An integer that represents the position of the instruction in the source code. The name of the attribute. The value of the attribute. Appends a frame representing a -valued attribute. The attribute is associated with the most recently added element. If the value is null and the current element is not a component, the frame will be omitted. An integer that represents the position of the instruction in the source code. The name of the attribute. The value of the attribute. Appends a frame representing a delegate-valued attribute. The attribute is associated with the most recently added element. If the value is null and the current element is not a component, the frame will be omitted. An integer that represents the position of the instruction in the source code. The name of the attribute. The value of the attribute. This method is provided for infrastructure purposes, and is used to be to provide support for delegates of specific types. For a good programming experience when using a custom delegate type, define an extension method similar to that calls this method. Appends a frame representing a string-valued attribute. The attribute is associated with the most recently added element. If the value is null, or the value false and the current element is not a component, the frame will be omitted. An integer that represents the position of the instruction in the source code. The name of the attribute. The value of the attribute. Appends a frame representing an attribute. The attribute is associated with the most recently added element. An integer that represents the position of the instruction in the source code. A holding the name and value of the attribute. Appends a frame representing a child component. The type of the child component. An integer that represents the position of the instruction in the source code. Appends a frame representing a child component. An integer that represents the position of the instruction in the source code. The type of the child component. Marks a previously appended component frame as closed. Calls to this method must be balanced with calls to . Appends a frame representing an instruction to capture a reference to the parent element. An integer that represents the position of the instruction in the source code. An action to be invoked whenever the reference value changes. Appends a frame representing an instruction to capture a reference to the parent component. An integer that represents the position of the instruction in the source code. An action to be invoked whenever the reference value changes. Clears the builder. Returns the values that have been appended. An array range of values. Describes changes to a component's render tree between successive renders. Gets the ID of the component. Gets the changes to the render tree since a previous state. Exists only so that the various methods in this class can call each other without constantly building up long lists of parameters. Is private to this class, so the fact that it's a mutable struct is manageable. Always pass by ref to avoid copying, and because the 'SiblingIndex' is mutable. Represents a single edit operation on a component's render tree. Gets the type of the edit operation. Gets the index of the sibling frame that the edit relates to. Gets the index of related data in an associated render frames array. For example, if the value is , gets the index of the new frame data in an associated render tree. If the value is , gets the name of the attribute that is being removed. Describes the type of a render tree edit operation. Indicates that a new frame should be inserted before the specified tree frame. Indicates that the specified tree frame should be removed. Indicates that an attribute value should be applied to the specified frame. This may be a change to an existing attribute, or the addition of a new attribute. Indicates that a named attribute should be removed from the specified frame. Indicates that the text content of the specified frame (which must be a text frame) should be updated. Indicates that the edit position should move inside the specified frame. Indicates that there are no further edit operations on the current frame, and the edit position should move back to the parent frame. Indicates that the markup content of the specified frame (which must be a markup frame) should be updated. Represents an entry in a tree of user interface (UI) items. Gets the sequence number of the frame. Sequence numbers indicate the relative source positions of the instructions that inserted the frames. Sequence numbers are only comparable within the same sequence (typically, the same source method). Describes the type of this frame. If the property equals gets the number of frames in the subtree for which this frame is the root. The value is zero if the frame has not yet been closed. If the property equals , gets a name representing the type of the element. Otherwise, the value is undefined. If the property equals , gets the content of the text frame. Otherwise, the value is undefined. If the property equals gets the ID of the corresponding event handler, if any. If the property equals , gets the attribute name. Otherwise, the value is undefined. If the property equals , gets the attribute value. Otherwise, the value is undefined. If the property equals gets the number of frames in the subtree for which this frame is the root. The value is zero if the frame has not yet been closed. If the property equals , gets the child component instance identifier. If the property equals , gets the type of the child component. If the property equals , gets the child component state object. Otherwise, the value is undefined. If the property equals , gets the child component instance. Otherwise, the value is undefined. If the property equals gets the number of frames in the subtree for which this frame is the root. The value is zero if the frame has not yet been closed. If the property equals , gets the ID of the reference capture. Otherwise, the value is undefined. If the property equals , gets the action that writes the reference to its target. Otherwise, the value is undefined. If the property equals , gets the index of the parent frame representing the component being captured. Otherwise, the value is undefined. WARNING: This index can only be used in the context of the frame's original render tree. If the frame is copied elsewhere, such as to the ReferenceFrames buffer of a RenderTreeDiff, then the index will not relate to entries in that other buffer. Currently there's no scenario where this matters, but if there was, we could change all of the subtree initialization logic in RenderTreeDiffBuilder to walk the frames hierarchically, then it would know the parent index at the point where it wants to initialize the ComponentReferenceCapture frame. If the property equals , gets the action that writes the reference to its target. Otherwise, the value is undefined. If the property equals , gets the content of the markup frame. Otherwise, the value is undefined. Describes the type of a . Represents a container for other frames. Represents text content. Represents a key-value pair associated with another . Represents a child component. Defines the boundary around range of sibling frames that should be treated as an unsplittable group for the purposes of diffing. This is typically used when appending a tree fragment generated by external code, because the sequence numbers in that tree fragment are not comparable to sequence numbers outside it. Represents an instruction to capture or update a reference to the parent element. Represents an instruction to capture or update a reference to the parent component. Represents a block of markup content. A component that renders an anchor tag, automatically toggling its 'active' class based on whether its 'href' matches the current URI. Gets or sets the CSS class name applied to the NavLink when the current route matches the NavLink href. Gets or sets a value representing the URL matching behavior. Modifies the URL matching behavior for a . Specifies that the should be active when it matches any prefix of the current URL. Specifies that the should be active when it matches the entire current URL. A component that displays whichever other component corresponds to the current navigation location. Gets or sets the assembly that should be searched, along with its referenced assemblies, for components matching the URI. Route precedence algorithm. We collect all the routes and sort them from most specific to less specific. The specificity of a route is given by the specificity of its segments and the position of those segments in the route. * A literal segment is more specific than a parameter segment. * A parameter segment with more constraints is more specific than one with fewer constraints * Segment earlier in the route are evaluated before segments later in the route. For example: /Literal is more specific than /Parameter /Route/With/{parameter} is more specific than /{multiple}/With/{parameters} /Product/{id:int} is more specific than /Product/{id} Routes can be ambiguous if: They are composed of literals and those literals have the same values (case insensitive) They are composed of a mix of literals and parameters, in the same relative order and the literals have the same values. For example: * /literal and /Literal /{parameter}/literal and /{something}/literal /{parameter:constraint}/literal and /{something:constraint}/literal To calculate the precedence we sort the list of routes as follows: * Shorter routes go first. * A literal wins over a parameter in precedence. * For literals with different values (case insensitive) we choose the lexical order * For parameters with different numbers of constraints, the one with more wins If we get to the end of the comparison routing we've detected an ambiguous pair of routes. A route constraint that requires the value to be parseable as a specified type. The type to which the value must be parseable. Helpers for working with URIs and navigation state. Gets the current absolute URI. The current absolute URI. An event that fires when the navigation location has changed. Converts a relative URI into an absolute one (by resolving it relative to the current absolute URI). The relative URI. The absolute URI. Gets the base URI (with trailing slash) that can be prepended before relative URI paths to produce an absolute URI. Typically this corresponds to the 'href' attribute on the document's <base> element. The URI prefix, which has a trailing slash. Given a base URI (e.g., one previously returned by ), converts an absolute URI into one relative to the base URI prefix. The base URI prefix (e.g., previously returned by ). An absolute URI that is within the space of the base URI. A relative URI path. Navigates to the specified URI. The destination URI. This can be absolute, or relative to the base URI (as returned by ). A base class for implementations. An event that fires when the navigation location has changed. Navigates to the specified URI. The destination URI. This can be absolute, or relative to the base URI (as returned by ). Navigates to the specified URI. The destination URI. This can be absolute, or relative to the base URI (as returned by ). Called to initialize BaseURI and current URI before those values the first time. Override this method to dynamically calculate the those values. Gets the current absolute URI. The current absolute URI. Gets the base URI (with trailing slash) that can be prepended before relative URI paths to produce an absolute URI. Typically this corresponds to the 'href' attribute on the document's <base> element. The URI prefix, which has a trailing slash. Converts a relative URI into an absolute one (by resolving it relative to the current absolute URI). The relative URI. The absolute URI. Given a base URI (e.g., one previously returned by ), converts an absolute URI into one relative to the base URI prefix. The base URI prefix (e.g., previously returned by ). An absolute URI that is within the space of the base URI. A relative URI path. Set the URI to the provided value. The URI. Must be an absolute URI. Calling does not trigger . Sets the base URI to the provided value (after normalization). The base URI. Must be an absolute URI. Calling does not trigger . Triggers the event with the current URI value. Supplies information about an event that is being raised. Gets or sets the type of the event. Supplies information about an input change event that is being raised. Gets or sets the new value of the input. This may be a or a . Supplies information about an clipboard event that is being raised. Supplies information about an drag event that is being raised. A count of consecutive clicks that happened in a short amount of time, incremented by one. The data that underlies a drag-and-drop operation, known as the drag data store. See . The X coordinate of the mouse pointer in global (screen) coordinates. The Y coordinate of the mouse pointer in global (screen) coordinates. The X coordinate of the mouse pointer in local (DOM content) coordinates. The Y coordinate of the mouse pointer in local (DOM content) coordinates. The button number that was pressed when the mouse event was fired: Left button=0, middle button=1 (if present), right button=2. For mice configured for left handed use in which the button actions are reversed the values are instead read from right to left. The buttons being pressed when the mouse event was fired: Left button=1, Right button=2, Middle (wheel) button=4, 4th button (typically, "Browser Back" button)=8, 5th button (typically, "Browser Forward" button)=16. If two or more buttons are pressed, returns the logical sum of the values. E.g., if Left button and Right button are pressed, returns 3 (=1 | 2). true if the control key was down when the event was fired. false otherwise. true if the shift key was down when the event was fired. false otherwise. true if the alt key was down when the event was fired. false otherwise. true if the meta key was down when the event was fired. false otherwise. The object is used to hold the data that is being dragged during a drag and drop operation. It may hold one or more , each of one or more data types. For more information about drag and drop, see HTML Drag and Drop API. Gets the type of drag-and-drop operation currently selected or sets the operation to a new type. The value must be none, copy, link or move. Provides all of the types of operations that are possible. Must be one of none, copy, copyLink, copyMove, link, linkMove, move, all or uninitialized. Contains a list of all the local files available on the data transfer. If the drag operation doesn't involve dragging files, this property is an empty list. Gives a array which is a list of all of the drag data. An array of giving the formats that were set in the dragstart event. The object represents one drag data item. During a drag operation, each drag event has a dataTransfer property which contains a list of drag data items. Each item in the list is a object. The kind of drag data item, string or file The drag data item's type, typically a MIME type Supplies information about an error event that is being raised. Gets a a human-readable error message describing the problem. Gets the name of the script file in which the error occurred. Gets the line number of the script file on which the error occurred. Gets the column number of the script file on which the error occurred. Supplies information about a focus event that is being raised. Supplies information about a keyboard event that is being raised. The key value of the key represented by the event. If the value has a printed representation, this attribute's value is the same as the char attribute. Otherwise, it's one of the key value strings specified in 'Key values'. If the key can't be identified, this is the string "Unidentified" Holds a string that identifies the physical key being pressed. The value is not affected by the current keyboard layout or modifier state, so a particular key will always return the same value. The location of the key on the device. true if a key has been depressed long enough to trigger key repetition, otherwise false. true if the control key was down when the event was fired. false otherwise. true if the shift key was down when the event was fired. false otherwise. true if the alt key was down when the event was fired. false otherwise. true if the meta key was down when the event was fired. false otherwise. Supplies information about a mouse event that is being raised. A count of consecutive clicks that happened in a short amount of time, incremented by one. The X coordinate of the mouse pointer in global (screen) coordinates. The Y coordinate of the mouse pointer in global (screen) coordinates. The X coordinate of the mouse pointer in local (DOM content) coordinates. The Y coordinate of the mouse pointer in local (DOM content) coordinates. The button number that was pressed when the mouse event was fired: Left button=0, middle button=1 (if present), right button=2. For mice configured for left handed use in which the button actions are reversed the values are instead read from right to left. The buttons being pressed when the mouse event was fired: Left button=1, Right button=2, Middle (wheel) button=4, 4th button (typically, "Browser Back" button)=8, 5th button (typically, "Browser Forward" button)=16. If two or more buttons are pressed, returns the logical sum of the values. E.g., if Left button and Right button are pressed, returns 3 (=1 | 2). true if the control key was down when the event was fired. false otherwise. true if the shift key was down when the event was fired. false otherwise. true if the alt key was down when the event was fired. false otherwise. true if the meta key was down when the event was fired. false otherwise. Supplies information about a mouse event that is being raised. A unique identifier for the pointer causing the event. The width (magnitude on the X axis), in CSS pixels, of the contact geometry of the pointer. The height (magnitude on the Y axis), in CSS pixels, of the contact geometry of the pointer. The normalized pressure of the pointer input in the range of 0 to 1, where 0 and 1 represent the minimum and maximum pressure the hardware is capable of detecting, respectively. The plane angle (in degrees, in the range of -90 to 90) between the Y-Z plane and the plane containing both the transducer (e.g. pen stylus) axis and the Y axis. The plane angle (in degrees, in the range of -90 to 90) between the X-Z plane and the plane containing both the transducer (e.g. pen stylus) axis and the X axis. Indicates the device type that caused the event. Must be one of the strings mouse, pen or touch, or an empty string. Indicates if the pointer represents the primary pointer of this pointer type. Supplies information about a progress event that is being raised. Whether or not the total size of the transfer is known. The number of bytes transferred since the beginning of the operation. This doesn't include headers and other overhead, but only the content itself. The total number of bytes of content that will be transferred during the operation. If the total size is unknown, this value is zero. Supplies information about a touch event that is being raised. A count of consecutive clicks that happened in a short amount of time, incremented by one. A list of for every point of contact currently touching the surface. A list of for every point of contact that is touching the surface and started on the element that is the target of the current event. A list of Touches for every point of contact which contributed to the event. For the touchstart event this must be a list of the touch points that just became active with the current event. For the touchmove event this must be a list of the touch points that have moved since the last event. For the touchend and touchcancel events this must be a list of the touch points that have just been removed from the surface. true if the control key was down when the event was fired. false otherwise. true if the shift key was down when the event was fired. false otherwise. true if the alt key was down when the event was fired. false otherwise. true if the meta key was down when the event was fired. false otherwise. Represents a single contact point on a touch-sensitive device. The contact point is commonly a finger or stylus and the device may be a touchscreen or trackpad. A unique identifier for this Touch object. A given touch point (say, by a finger) will have the same identifier for the duration of its movement around the surface. This lets you ensure that you're tracking the same touch all the time. The X coordinate of the touch point relative to the left edge of the screen. The Y coordinate of the touch point relative to the top edge of the screen. The X coordinate of the touch point relative to the left edge of the browser viewport, not including any scroll offset. The Y coordinate of the touch point relative to the top edge of the browser viewport, not including any scroll offset. The X coordinate of the touch point relative to the left edge of the document. Unlike , this value includes the horizontal scroll offset, if any. The Y coordinate of the touch point relative to the top of the document. Unlike , this value includes the vertical scroll offset, if any. Supplies information about a mouse wheel event that is being raised. The horizontal scroll amount. The vertical scroll amount. The scroll amount for the z-axis. The unit of the delta values scroll amount. Extensions methods on for event handlers. These methods enable method-group to delegate conversion for delegates and methods that accept types derived from . This enhances the programming experience for using event handlers with the render tree builder in components written in pure C#. These extension methods make it possible to write code like: builder.AddAttribute(0, "onkeypress", MyKeyPressHandler); Where void MyKeyPressHandler(UIKeyboardEventArgs e) is a method defined in the same class. In this example, the author knows that the onclick event is associated with the event args type. The component author is responsible for providing a delegate that matches the expected event args type, an error will result in a failure at runtime. When a component is authored in Razor (.cshtml), the Razor code generator will maintain a mapping between event names and event arg types that can be used to generate more strongly typed code. Generated code for the same case will look like: builder.AddAttribute(0, "onkeypress", BindMethods.GetEventHandlerValue<UIKeyboardEventArgs>(MyKeyPressHandler)); Appends a frame representing an -valued attribute. The attribute is associated with the most recently added element. If the value is null and the current element is not a component, the frame will be omitted. The . An integer that represents the position of the instruction in the source code. The name of the attribute. The value of the attribute. Appends a frame representing an -valued attribute. The attribute is associated with the most recently added element. If the value is null and the current element is not a component, the frame will be omitted. The . An integer that represents the position of the instruction in the source code. The name of the attribute. The value of the attribute. Appends a frame representing an -valued attribute. The attribute is associated with the most recently added element. If the value is null and the current element is not a component, the frame will be omitted. The . An integer that represents the position of the instruction in the source code. The name of the attribute. The value of the attribute. Appends a frame representing an -valued attribute. The attribute is associated with the most recently added element. If the value is null and the current element is not a component, the frame will be omitted. The . An integer that represents the position of the instruction in the source code. The name of the attribute. The value of the attribute. Appends a frame representing an -valued attribute. The attribute is associated with the most recently added element. If the value is null and the current element is not a component, the frame will be omitted. The . An integer that represents the position of the instruction in the source code. The name of the attribute. The value of the attribute. Appends a frame representing an -valued attribute. The attribute is associated with the most recently added element. If the value is null and the current element is not a component, the frame will be omitted. The . An integer that represents the position of the instruction in the source code. The name of the attribute. The value of the attribute. Appends a frame representing an -valued attribute. The attribute is associated with the most recently added element. If the value is null and the current element is not a component, the frame will be omitted. The . An integer that represents the position of the instruction in the source code. The name of the attribute. The value of the attribute. Appends a frame representing an -valued attribute. The attribute is associated with the most recently added element. If the value is null and the current element is not a component, the frame will be omitted. The . An integer that represents the position of the instruction in the source code. The name of the attribute. The value of the attribute. Appends a frame representing an -valued attribute. The attribute is associated with the most recently added element. If the value is null and the current element is not a component, the frame will be omitted. The . An integer that represents the position of the instruction in the source code. The name of the attribute. The value of the attribute. Appends a frame representing an -valued attribute. The attribute is associated with the most recently added element. If the value is null and the current element is not a component, the frame will be omitted. The . An integer that represents the position of the instruction in the source code. The name of the attribute. The value of the attribute. Appends a frame representing an -valued attribute. The attribute is associated with the most recently added element. If the value is null and the current element is not a component, the frame will be omitted. The . An integer that represents the position of the instruction in the source code. The name of the attribute. The value of the attribute. Appends a frame representing an -valued attribute. The attribute is associated with the most recently added element. If the value is null and the current element is not a component, the frame will be omitted. The . An integer that represents the position of the instruction in the source code. The name of the attribute. The value of the attribute. Appends a frame representing an -valued attribute. The attribute is associated with the most recently added element. If the value is null and the current element is not a component, the frame will be omitted. The . An integer that represents the position of the instruction in the source code. The name of the attribute. The value of the attribute. Appends a frame representing an -valued attribute. The attribute is associated with the most recently added element. If the value is null and the current element is not a component, the frame will be omitted. The . An integer that represents the position of the instruction in the source code. The name of the attribute. The value of the attribute. Appends a frame representing an -valued attribute. The attribute is associated with the most recently added element. If the value is null and the current element is not a component, the frame will be omitted. The . An integer that represents the position of the instruction in the source code. The name of the attribute. The value of the attribute. Appends a frame representing an -valued attribute. The attribute is associated with the most recently added element. If the value is null and the current element is not a component, the frame will be omitted. The . An integer that represents the position of the instruction in the source code. The name of the attribute. The value of the attribute. Appends a frame representing an -valued attribute. The attribute is associated with the most recently added element. If the value is null and the current element is not a component, the frame will be omitted. The . An integer that represents the position of the instruction in the source code. The name of the attribute. The value of the attribute. Appends a frame representing an -valued attribute. The attribute is associated with the most recently added element. If the value is null and the current element is not a component, the frame will be omitted. The . An integer that represents the position of the instruction in the source code. The name of the attribute. The value of the attribute. Appends a frame representing an -valued attribute. The attribute is associated with the most recently added element. If the value is null and the current element is not a component, the frame will be omitted. The . An integer that represents the position of the instruction in the source code. The name of the attribute. The value of the attribute. Appends a frame representing an -valued attribute. The attribute is associated with the most recently added element. If the value is null and the current element is not a component, the frame will be omitted. The . An integer that represents the position of the instruction in the source code. The name of the attribute. The value of the attribute. Appends a frame representing an -valued attribute. The attribute is associated with the most recently added element. If the value is null and the current element is not a component, the frame will be omitted. The . An integer that represents the position of the instruction in the source code. The name of the attribute. The value of the attribute. Appends a frame representing an -valued attribute. The attribute is associated with the most recently added element. If the value is null and the current element is not a component, the frame will be omitted. The . An integer that represents the position of the instruction in the source code. The name of the attribute. The value of the attribute. ================================================ FILE: src/Microsoft.JSInterop.xml ================================================ Microsoft.JSInterop Provides methods that receive incoming calls from JS to .NET. Receives a call from JS to .NET, locating and invoking the specified method. The assembly containing the method to be invoked. The identifier of the method to be invoked. The method must be annotated with a matching this identifier string. For instance method calls, identifies the target object. A JSON representation of the parameters. A JSON representation of the return value, or null. Receives a call from JS to .NET, locating and invoking the specified method asynchronously. A value identifying the asynchronous call that should be passed back with the result, or null if no result notification is required. The assembly containing the method to be invoked. The identifier of the method to be invoked. The method must be annotated with a matching this identifier string. For instance method calls, identifies the target object. A JSON representation of the parameters. A JSON representation of the return value, or null. Receives notification that a call from .NET to JS has finished, marking the associated as completed. The identifier for the function invocation. A flag to indicate whether the invocation succeeded. If is true, specifies the invocation result. If is false, gives the corresponding to the invocation failure. Releases the reference to the specified .NET object. This allows the .NET runtime to garbage collect that object if there are no other references to it. To avoid leaking memory, the JavaScript side code must call this for every .NET object it obtains a reference to. The exception is if that object is used for the entire lifetime of a given user's session, in which case it is released automatically when the JavaScript runtime is disposed. The identifier previously passed to JavaScript code. Wraps a JS interop argument, indicating that the value should not be serialized as JSON but instead should be passed as a reference. To avoid leaking memory, the reference must later be disposed by JS code or by .NET code. Gets the object instance represented by this wrapper. Constructs an instance of . The value being wrapped. Ensures the is associated with the specified . Developers do not normally need to invoke this manually, since it is called automatically by framework code. The . Stops tracking this object reference, allowing it to be garbage collected (if there are no other references to it). Once the instance is disposed, it can no longer be used in interop calls from JavaScript code. Internal. Intended for framework use only. Internal. Intended for framework use only. Intended for framework use only. Constructs an instance of . The result of the call. Represents an instance of a JavaScript runtime to which calls may be dispatched. Invokes the specified JavaScript function synchronously. The JSON-serializable return type. An identifier for the function to invoke. For example, the value "someScope.someFunction" will invoke the function window.someScope.someFunction. JSON-serializable arguments. An instance of obtained by JSON-deserializing the return value. Represents an instance of a JavaScript runtime to which calls may be dispatched. Invokes the specified JavaScript function asynchronously. The JSON-serializable return type. An identifier for the function to invoke. For example, the value "someScope.someFunction" will invoke the function window.someScope.someFunction. JSON-serializable arguments. An instance of obtained by JSON-deserializing the return value. Stops tracking the .NET object represented by the . This allows it to be garbage collected (if nothing else holds a reference to it) and means the JS-side code can no longer invoke methods on the instance or pass it as an argument to subsequent calls. The reference to stop tracking. This method is called automaticallly by . Stops tracking the specified .NET object reference. This overload is typically invoked from JS code via JS interop. The ID of the . Stops tracking the specified .NET object reference. This overload is typically invoked from .NET code by . The . Represents errors that occur during an interop call from .NET to JavaScript. Constructs an instance of . The exception message. Abstract base class for an in-process JavaScript runtime. Invokes the specified JavaScript function synchronously. The JSON-serializable return type. An identifier for the function to invoke. For example, the value "someScope.someFunction" will invoke the function window.someScope.someFunction. JSON-serializable arguments. An instance of obtained by JSON-deserializing the return value. Performs a synchronous function invocation. The identifier for the function to invoke. A JSON representation of the arguments. A JSON representation of the result. Identifies a .NET method as allowing invocation from JavaScript code. Any method marked with this attribute may receive arbitrary parameter values from untrusted callers. All inputs should be validated carefully. Gets the identifier for the method. The identifier must be unique within the scope of an assembly. If not set, the identifier is taken from the name of the method. In this case the method name must be unique within the assembly. Constructs an instance of without setting an identifier for the method. Constructs an instance of using the specified identifier. An identifier for the method, which must be unique within the scope of the assembly. Provides mechanisms for converting between .NET objects and JSON strings for use when making calls to JavaScript functions via . Warning: This is not intended as a general-purpose JSON library. It is only intended for use when making calls via . Eventually its implementation will be replaced by something more general-purpose. Serializes the value as a JSON string. The value to serialize. The JSON string. Deserializes the JSON string, creating an object of the specified generic type. The type of object to create. The JSON string. An object of the specified type. Provides mechanisms for accessing the current . Gets the current , if any. Sets the current JS runtime to the supplied instance. This is intended for framework use. Developers should not normally need to call this method. The new current . Abstract base class for a JavaScript runtime. Constructs an instance of . Invokes the specified JavaScript function asynchronously. The JSON-serializable return type. An identifier for the function to invoke. For example, the value "someScope.someFunction" will invoke the function window.someScope.someFunction. JSON-serializable arguments. An instance of obtained by JSON-deserializing the return value. Begins an asynchronous function invocation. The identifier for the function invocation, or zero if no async callback is required. The identifier for the function to invoke. A JSON representation of the arguments. Represents the json array. Initializes a new instance of the class. Initializes a new instance of the class. The capacity of the json array. The json representation of the array. The json representation of the array. Represents the json object. The internal member dictionary. Initializes a new instance of . Initializes a new instance of . The implementation to use when comparing keys, or null to use the default for the type of the key. Gets the at the specified index. Adds the specified key. The key. The value. Determines whether the specified key contains key. The key. true if the specified key contains key; otherwise, false. Gets the keys. The keys. Removes the specified key. The key. Tries the get value. The key. The value. Gets the values. The values. Gets or sets the with the specified key. Adds the specified item. The item. Clears this instance. Determines whether [contains] [the specified item]. The item. true if [contains] [the specified item]; otherwise, false. Copies to. The array. Index of the array. Gets the count. The count. Gets a value indicating whether this instance is read only. true if this instance is read only; otherwise, false. Removes the specified item. The item. Gets the enumerator. Returns an enumerator that iterates through a collection. An object that can be used to iterate through the collection. Returns a json that represents the current . A json that represents the current . This class encodes and decodes JSON strings. Spec. details, see http://www.json.org/ JSON uses Arrays and Objects. These correspond here to the datatypes JsonArray(IList<object>) and JsonObject(IDictionary<string,object>). All numbers are parsed to doubles. Parses the string json into a value A JSON string. An IList<object>, a IDictionary<string,object>, a double, a string, null, true, or false Try parsing the json string into a value. A JSON string. The object. Returns true if successful otherwise false. Converts a IDictionary<string,object> / IList<object> object into a JSON string A IDictionary<string,object> / IList<object> Serializer strategy to use A JSON encoded string, or null if object 'json' is not serializable Determines if a given object is numeric in any way (can be integer, double, null, etc). ================================================ FILE: template/index.html.tmpl ================================================ {{!Copyright (c) Microsoft. All rights reserved. Licensed under the MIT license. See LICENSE file in the project root for full license information.}} {{!include(/^styles/.*/)}} {{!include(/^fonts/.*/)}} {{!include(favicon.ico)}} {{!include(logo.svg)}} {{>partials/head}}
    {{>partials/navbar}}
    Experimental
    {{{conceptual}}} {{>partials/footer}}
    {{>partials/scripts}} ================================================ FILE: template/styles/main.css ================================================ body { font-size: 16px; } .toc .level1 > li { font-weight: normal; } h1, h2 { font-family: segoe-ui_light,Segoe UI Light,Segoe WP,Helvetica Neue,Helvetica,sans-serif; } .anchorjs-link { display: none; } .hero { color: #c2e0f9; background-color: #385361; background-image: -webkit-gradient(linear,left bottom,right top,color-stop(0%,#1e1e90),color-stop(100%,#385361)); background-image: -webkit-linear-gradient(180deg,#1e1e90 0,#337ab7 100%); background-image: -moz-linear-gradient(180deg,#1e1e90 0,#337ab7 100%); background-image: -ms-linear-gradient(180deg,#1e1e90 0,#337ab7 100%); background-image: -o-linear-gradient(180deg,#1e1e90 0,#337ab7 100%); background-image: linear-gradient(180deg,#1e1e90 0,#337ab7 100%); filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#1e1e90', endColorstr='#337ab7', GradientType=1); } .hero strong { color: #e7e7e7; } .btn-primary, .btn-primary:visited, .btn-primary:focus, .button, .button:visited, .button:focus { background-color: #42a044; color: #fff; border-color: #8f9eab; -webkit-box-shadow: 3px 4px 1px rgba(50, 50, 50, 0.75); -moz-box-shadow: 3px 4px 1px rgba(50, 50, 50, 0.75); box-shadow: 3px 4px 1px rgba(50, 50, 50, 0.75); } .btn-primary:hover, .btn-primary:active, .button:hover, .button:active { background-color: #388439; color: #fff; border-color: #8f9eab; } svg:hover path { fill: #ffffff; } .counter-key-section{ border: 2px solid #6E8B60; -webkit-border-image-source: -webkit-gradient(linear, left, right, color-stop(0%, rgba(0, 0, 0, 0)), color-stop(50%, #385361), color-stop(100%, rgba(0, 0, 0, 0))); -webkit-border-image-source: -webkit-linear-gradient(90deg, rgba(0, 0, 0, 0), #385361 50%, rgba(0, 0, 0, 0)); -moz-border-image-source: -moz-linear-gradient(90deg, rgba(0, 0, 0, 0), #385361 50%, rgba(0, 0, 0, 0)); -ms-border-image-source: -ms-linear-gradient(90deg, rgba(0, 0, 0, 0), #385361 50%, rgba(0, 0, 0, 0)); -o-border-image-source: -o-linear-gradient(90deg, rgba(0, 0, 0, 0), #385361 50%, rgba(0, 0, 0, 0)); border-image-source: linear-gradient(90deg, rgba(0, 0, 0, 0), #385361 50%, rgba(0, 0, 0, 0)); border-image-slice: 1; } .value-prop-heading { font-size: 24px; } #vp-container{ margin-top: 30px; } .hero { height: 350px; margin-top: 50px; padding-top: 50px; font-weight: 300; text-align: center; } .key-section{ padding: 30px 0; } .key-section .glyphicon, .counter-key-section .glyphicon { font-size: 8em; padding: 50px; display: table-cell; vertical-align: middle; } .glyphicon { margin-right: 10px; font-size: 16px; } .key-section section, .counter-key-section section { display: table-cell; padding: 40px; } .key-section section p, .counter-key-section section p { text-align: initial; } .counter-key-section{ padding: 30px 0; } .get-started-section section { padding-bottom: 50px; } .buttons-unit-small{ font-size: 16px; font-weight: normal; } .version-link, .github-link{ margin: 5px; } .hero strong { font-weight: 400; } .hero .text { font-size: 64px; text-align: center; font-family: 'Segoe UI', Tahoma, Helvetica, sans-serif; } .hero .minitext { font-size: 20px; text-align: center; } .buttons-unit { margin-top: 50px; text-align: center; } .hero .button { border-radius: 4px; padding: 8px 16px; margin: 0 12px; box-shadow: 1px 3px 3px rgba(0,0,0,0.3); } .buttons-unit .button { font-size: 24px; } @media only screen and (max-width: 768px) { .hero { margin-top: 0px; } .hero .button { display: block; margin: 12px; } .cr { display: none; } .key-section .glyphicon { display: none; } .counter-key-section .glyphicon { display: none; } } .footer { padding: 15px; } /* Corner Ribbon Styles */ .cr { width: 200px; padding: 16px; position: absolute; text-align: center; color: #f0f0f0; z-index: 1000; } .cr-sticky { position: fixed; } /* Positions */ .cr-top { top: 25px; } .cr-bottom { bottom: 25px; } .cr-left { left: -50px; } .cr-right { right: -50px; } /* Rotations */ .cr-top.cr-left, .cr-bottom.cr-right { transform: rotate(-45deg); } .cr-top.cr-right, .cr-bottom.cr-left { transform: rotate(45deg); } /* Colors */ .cr-white { background-color: #f0f0f0; color: #444; } .cr-black { background-color: #333; } .cr-grey { background-color: #999; } .cr-blue { background-color: #39d; } .cr-green { background-color: #42a044; } .cr-turquoise { background-color: #1b9; } .cr-purple { background-color: #95b; } .cr-red { background-color: #e43; } .cr-orange { background-color: #e82; } .cr-yellow { background-color: #ec0; } ================================================ FILE: toc.yml ================================================ - name: Docs href: https://docs.microsoft.com/aspnet/core/blazor/ - name: API href: api/ homepage: api/index.md - name: Community href: community.md - name: Blog href: https://blogs.msdn.microsoft.com/webdev/category/blazor/