To setup a basic navigation in Angular Material, type the following command in your terminal (e.g. I am using WebStorm IDE):
$ ng generate @angular/material:material.nav -name=main-nav
This will create a component named main-nav with all basic elements, fully responsive and free to modify.
Posts mit dem Label howto werden angezeigt. Alle Posts anzeigen
Posts mit dem Label howto werden angezeigt. Alle Posts anzeigen
Montag, 7. Oktober 2019
How to create Nav with Angular + Angular Material
Mittwoch, 15. Mai 2019
How to remove line breaks etc. in Java String
myString.trim() .replace("\n", "") .replace("\r", "") .replace(System.getProperty("line.separator"), "");
Donnerstag, 18. April 2019
Remove duplicates in list with Java > 8
//remove duplicates from a list with Java 8 or greater
mylist.stream().distinct.collect(Collectors.toList())
Mittwoch, 17. April 2019
Mock static methods with Mockito in Java (mock, static, method, java)
import org.junit.Test; import org.junit.runner.RunWith; import org.mockito.BDDMockito; import org.powermock.api.mockito.PowerMockito; import org.powermock.core.classloader.annotations.PrepareForTest; import org.powermock.modules.junit4.PowerMockRunner;
@RunWith(PowerMockRunner.class) @PrepareForTest(MyStatic.class) ... @Test
public void someTest() {
//given
PowerMockito.mockStatic(MyStatic.class); BDDMockito.given(MyStatic.someStaticMethod()).willReturn(...); //when ... //then
PowerMockito.verifyStatic(); MyStatic.someStaticMethod(); assertThat(//your further asserts....
Abonnieren
Posts (Atom)
NEW BLOG! http://cleancode.consulting/
Dear Reader, This Blog is closed and remains as an archive. Please find our new Blog at http://cleancode.consulting/
-
This is a fine one: if you only do have XML and nothing else, you can generate an XSD from the XML ( here ) and use the XSD to generate your...
-
Dear Reader, This Blog is closed and remains as an archive. Please find our new Blog at http://cleancode.consulting/