Security News
Fluent Assertions Faces Backlash After Abandoning Open Source Licensing
Fluent Assertions is facing backlash after dropping the Apache license for a commercial model, leaving users blindsided and questioning contributor rights.
ngx-i18n-country-select
Advanced tools
> Angular wrapper for [i18n-iso-countries](https://github.com/michaelwittig/node-i18n-iso-countries).
Angular wrapper for i18n-iso-countries.
npm install i18n-iso-countries --save
npm install ngx-i18n-country-select --save
// app.module.ts
import { NgModule, LOCALE_ID, APP_INITIALIZER } from '@angular/core';
import { BrowserModule } from '@angular/platform-browser';
import { I18nCountrySelectModule, I18nCountrySelectService } from 'ngx-i18n-country-select';
export function setUpI18nCountrySelect(service: I18nCountrySelectService) {
return () => service.use(['de', 'en']);
}
@NgModule({
declarations: [AppComponent],
imports: [BrowserModule, I18nCountrySelectModule.forRoot()],
providers: [
{ provide: LOCALE_ID, useValue: 'de-DE' },
I18nCountrySelectService,
{
provide: APP_INITIALIZER,
useFactory: setUpI18nCountrySelect,
deps: [I18nCountrySelectService],
multi: true
}
],
bootstrap: [AppComponent]
})
export class AppModule {}
// app.component.ts
import { Component } from '@angular/core';
@Component({
selector: 'app-root',
templateUrl: './app.component.html'
})
export class AppComponent {
item = {
isocode: 'de'
};
}
<i18n-country-select [(iso3166Alpha2)]="item.isocode" size="sm"></i18n-country-select>
Demo on stackblitz
attribute | type | description |
---|---|---|
iso3166Alpha2 | Object | model as ISO 3166-1 Alpha2 |
size | string | 'sm' , 'lg' . default: nothing. |
pleaseChoose | string | default option label. default: 'Please choose...' . |
mandatory | boolean | make select required. default: false |
editable | boolean | enable or disable select. default: true |
mandatory
to set required attributegit branch -m master main
git fetch origin
git branch -u origin/main main
MIT © Oliver Sahner
FAQs
> Angular wrapper for [i18n-iso-countries](https://github.com/michaelwittig/node-i18n-iso-countries).
We found that ngx-i18n-country-select demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Fluent Assertions is facing backlash after dropping the Apache license for a commercial model, leaving users blindsided and questioning contributor rights.
Research
Security News
Socket researchers uncover the risks of a malicious Python package targeting Discord developers.
Security News
The UK is proposing a bold ban on ransomware payments by public entities to disrupt cybercrime, protect critical services, and lead global cybersecurity efforts.