Skip to content

Commit dd78b72

Browse files
author
json-api-cibuild
committed
Automated commit from cibuild
1 parent 5b656ca commit dd78b72

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

usage/resource-graph.html

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,7 @@ <h3 id="auto-discovery">Auto-discovery</h3>
9696
<p>The following command builds the resource graph using all <code>IIdentifiable</code> implementations and registers the services mentioned.
9797
You can enable auto-discovery for the current assembly by adding the following at startup.</p>
9898
<pre><code class="lang-c#">// Program.cs
99-
builder.Services.AddJsonApi(discovery =&gt; discovery.AddCurrentAssembly());
99+
builder.Services.AddJsonApi(discovery: discovery =&gt; discovery.AddCurrentAssembly());
100100
</code></pre>
101101
<h3 id="specifying-an-entity-framework-core-dbcontext">Specifying an Entity Framework Core DbContext</h3>
102102
<p>If you are using Entity Framework Core as your ORM, you can add all the models of a <code>DbContext</code> to the resource graph.</p>
@@ -105,7 +105,7 @@ <h3 id="specifying-an-entity-framework-core-dbcontext">Specifying an Entity Fram
105105
</code></pre>
106106
<p>Be aware that this does not register resource definitions, resource services and repositories. You can combine it with auto-discovery to achieve this.</p>
107107
<pre><code class="lang-c#">// Program.cs
108-
builder.Services.AddJsonApi&lt;AppDbContext&gt;(discovery =&gt; discovery.AddCurrentAssembly());
108+
builder.Services.AddJsonApi&lt;AppDbContext&gt;(discovery: discovery =&gt; discovery.AddCurrentAssembly());
109109
</code></pre>
110110
<h3 id="manual-specification">Manual Specification</h3>
111111
<p>You can manually construct the graph.</p>

0 commit comments

Comments
 (0)