Cydo
Cydo
Explore posts from servers
CC#
Created by Cydo on 12/4/2024 in #help
How can I make FluentValidation return errors in camel case??
Program.cs
// JSON and FluentValidation Configuration
builder.Services.AddControllers()
.AddJsonOptions(options => { options.JsonSerializerOptions.PropertyNamingPolicy = JsonNamingPolicy.CamelCase; });

// Use the DependencyInjection method for adding EmailService
builder.Services.AddInfrastructureServices(builder.Configuration);

// FluentValidation Setup
builder.Services.AddFluentValidationAutoValidation()
.AddFluentValidationClientsideAdapters();

// Register Validators
builder.Services.AddValidatorsFromAssemblyContaining<LoginCredentialsRequestDtoValidator>();
builder.Services.AddValidatorsFromAssemblyContaining<RegisterCredentialsRequestDtoValidator>();
builder.Services.AddValidatorsFromAssemblyContaining<TokenDtoRequestValidator>();
builder.Services.AddValidatorsFromAssemblyContaining<CreatePartyRequestDtoValidator>();
builder.Services.AddValidatorsFromAssemblyContaining<ChangePasswordRequestDtoValidator>();
builder.Services.AddValidatorsFromAssemblyContaining<ForgotPasswordRequestDtoValidator>();
builder.Services.AddValidatorsFromAssemblyContaining<ResetPasswordRequestDtoValidator>();

// Register the CamelCaseValidationInterceptor manually
builder.Services.AddScoped<IValidatorInterceptor, CamelCaseValidationInterceptor>();
// JSON and FluentValidation Configuration
builder.Services.AddControllers()
.AddJsonOptions(options => { options.JsonSerializerOptions.PropertyNamingPolicy = JsonNamingPolicy.CamelCase; });

// Use the DependencyInjection method for adding EmailService
builder.Services.AddInfrastructureServices(builder.Configuration);

// FluentValidation Setup
builder.Services.AddFluentValidationAutoValidation()
.AddFluentValidationClientsideAdapters();

// Register Validators
builder.Services.AddValidatorsFromAssemblyContaining<LoginCredentialsRequestDtoValidator>();
builder.Services.AddValidatorsFromAssemblyContaining<RegisterCredentialsRequestDtoValidator>();
builder.Services.AddValidatorsFromAssemblyContaining<TokenDtoRequestValidator>();
builder.Services.AddValidatorsFromAssemblyContaining<CreatePartyRequestDtoValidator>();
builder.Services.AddValidatorsFromAssemblyContaining<ChangePasswordRequestDtoValidator>();
builder.Services.AddValidatorsFromAssemblyContaining<ForgotPasswordRequestDtoValidator>();
builder.Services.AddValidatorsFromAssemblyContaining<ResetPasswordRequestDtoValidator>();

// Register the CamelCaseValidationInterceptor manually
builder.Services.AddScoped<IValidatorInterceptor, CamelCaseValidationInterceptor>();
2 replies
CC#
Created by Cydo on 11/27/2024 in #help
✅ How can I take 2 existing repos (client and backend) and combine them?
you're the goat, thanks
39 replies
CC#
Created by Cydo on 11/28/2024 in #help
✅ Setup SendGrid to send emails, but not getting them
Well my work around was to not use sendgrid at all and instead use MailKit, and set that up to use gmails smtpHost and port and a google app password to allow emails to be sent from a gmail account. Not sure if this is a good idea but I cant send emails at least lol
3 replies
CC#
Created by Cydo on 11/28/2024 in #help
✅ Setup SendGrid to send emails, but not getting them
I have about 7 of these in my acitivty feed and they all are like this
3 replies
CC#
Created by Cydo on 11/27/2024 in #help
✅ How can I take 2 existing repos (client and backend) and combine them?
When you have time can you tell me how you made this fancy explanation lol
39 replies
CC#
Created by Cydo on 11/27/2024 in #help
✅ How can I take 2 existing repos (client and backend) and combine them?
Ok then ill do that, thanks
39 replies
CC#
Created by Cydo on 11/27/2024 in #help
✅ How can I take 2 existing repos (client and backend) and combine them?
Wait, should I maybe keep them a seperate repos then? I've never done docker before, but I got a raspberry pi, setup a linux server and i wanna dockerize my react frontend, .net backend and mssql db and put it all on my pi, and then setup automated deployments like when i update my git repo is automatically deploys the update, is that gonna be easier as separate repos?
39 replies
CC#
Created by Cydo on 11/27/2024 in #help
✅ How can I take 2 existing repos (client and backend) and combine them?
HOpefully that makes sense
39 replies
CC#
Created by Cydo on 11/27/2024 in #help
✅ How can I take 2 existing repos (client and backend) and combine them?
yeah i dont wanna merge the repos together, i just want one repo where the separate frontend and backend exist.
39 replies
CC#
Created by Cydo on 11/27/2024 in #help
✅ How can I take 2 existing repos (client and backend) and combine them?
is this a viable way to do things without subtrees? https://github.com/CydoEntis/collabparty
39 replies
CC#
Created by Cydo on 11/27/2024 in #help
✅ How can I take 2 existing repos (client and backend) and combine them?
Alright ill look up git subtrees, I just made a new git repo and cloned both existing repos into it, but idk if thats gonna work
39 replies
CC#
Created by Cydo on 11/27/2024 in #help
✅ How can I take 2 existing repos (client and backend) and combine them?
or at least enough to be a semi-wizard lol
39 replies
CC#
Created by Cydo on 11/27/2024 in #help
✅ How can I take 2 existing repos (client and backend) and combine them?
I plan to fully learn git one of the days,
39 replies
CC#
Created by Cydo on 11/27/2024 in #help
✅ How can I take 2 existing repos (client and backend) and combine them?
my git knowledge extends to, i can push and pull and make repos if something goes wrong , go into panic mode, i can resolve merge conflicts when they happen tho
39 replies
CC#
Created by Cydo on 11/27/2024 in #help
✅ How can I take 2 existing repos (client and backend) and combine them?
Alright ill look into this more, i wanna take my 2 separate repos and make them one repo, so its easier to manage, but i dont wanna fuck anything up lol
39 replies
CC#
Created by Cydo on 11/27/2024 in #help
✅ How can I take 2 existing repos (client and backend) and combine them?
yeah this is what i do, i just wanted to better organize my projects/git repos
39 replies
CC#
Created by Cydo on 11/27/2024 in #help
✅ How can I take 2 existing repos (client and backend) and combine them?
So, thats still one repo, and theres only .gitignore that handles "projects"
39 replies
CC#
Created by Cydo on 11/27/2024 in #help
✅ How can I take 2 existing repos (client and backend) and combine them?
thats what i was trying to do but having the .gitignore at the root confused me
39 replies
CC#
Created by Cydo on 11/27/2024 in #help
✅ How can I take 2 existing repos (client and backend) and combine them?
Just thought one repo is easier to share then 2 separate ones
39 replies
CC#
Created by Cydo on 11/27/2024 in #help
✅ How can I take 2 existing repos (client and backend) and combine them?
Is that common practice? I have them separate as of now, every repo ive ever made is separate
39 replies