-
Notifications
You must be signed in to change notification settings - Fork 34
Closed
Labels
ServerImprovements or additions to the server codeImprovements or additions to the server code
Milestone
Description
Describe the bug
I tried to use the steps as given in the Getting Started > Datasync server page, but the resulting csproj had these problematic lines in it:
<PackageReference Include="CommunityToolkit.Datasync.Server" Version="{NUGET_VERSION}" />
<PackageReference Include="CommunityToolkit.Datasync.Server.EntityFrameworkCore" Version="{NUGET_VERSION}" />
I replaced those with actual version numbers; but next, the resulting Program.cs has this error:
'IServiceCollection' does not contain a definition for 'AddDatasyncControllers' and no accessible extension method 'AddDatasyncControllers' accepting a first argument of type 'IServiceCollection' could be found (are you missing a using directive or an assembly reference?)
on this line:
builder.Services.AddDatasyncControllers();
To Reproduce
Steps to reproduce the behavior:
Follow the steps given on the Getting Started page:
- Install the datasync template:
dotnet new -i CommunityToolkit.Datasync.Server.Template.CSharp - Create a project:
dotnet new datasync-server - See Package Reference error in .csproj
- Fix that error by substituting version number 8.04
- Re-open project; see
AddDatasyncControllerserror in Program.cs
Expected behavior
That the program as documented in Getting Started will work without errors.
What platforms?
Windows 11.
Metadata
Metadata
Assignees
Labels
ServerImprovements or additions to the server codeImprovements or additions to the server code