How to use the autolinker.UrlMatch function in autolinker

To help you get started, we’ve selected a few autolinker examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github gregjacobs / Autolinker.js / tests-integration / test-require.spec.ts View on Github external
expect( Autolinker.EmailMatch.name ).toBe( 'EmailMatch' );  // function name
		expect( Autolinker.EmailMatch.prototype.getEmail ).toEqual( jasmine.any( Function ) );

		expect( Autolinker.HashtagMatch ).toEqual( jasmine.any( Function ) );  // constructor function
		expect( Autolinker.HashtagMatch.name ).toBe( 'HashtagMatch' );  // function name
		expect( Autolinker.HashtagMatch.prototype.getHashtag ).toEqual( jasmine.any( Function ) );

		expect( Autolinker.MentionMatch ).toEqual( jasmine.any( Function ) );  // constructor function
		expect( Autolinker.MentionMatch.name ).toBe( 'MentionMatch' );  // function name
		expect( Autolinker.MentionMatch.prototype.getMention ).toEqual( jasmine.any( Function ) );

		expect( Autolinker.PhoneMatch ).toEqual( jasmine.any( Function ) );  // constructor function
		expect( Autolinker.PhoneMatch.name ).toBe( 'PhoneMatch' );  // function name
		expect( Autolinker.PhoneMatch.prototype.getNumber ).toEqual( jasmine.any( Function ) );

		expect( Autolinker.UrlMatch ).toEqual( jasmine.any( Function ) );  // constructor function
		expect( Autolinker.UrlMatch.name ).toBe( 'UrlMatch' );  // function name
		expect( Autolinker.UrlMatch.prototype.getUrl ).toEqual( jasmine.any( Function ) );
	} );
github gregjacobs / Autolinker.js / tests-integration / test-require.spec.ts View on Github external
expect( Autolinker.HashtagMatch ).toEqual( jasmine.any( Function ) );  // constructor function
		expect( Autolinker.HashtagMatch.name ).toBe( 'HashtagMatch' );  // function name
		expect( Autolinker.HashtagMatch.prototype.getHashtag ).toEqual( jasmine.any( Function ) );

		expect( Autolinker.MentionMatch ).toEqual( jasmine.any( Function ) );  // constructor function
		expect( Autolinker.MentionMatch.name ).toBe( 'MentionMatch' );  // function name
		expect( Autolinker.MentionMatch.prototype.getMention ).toEqual( jasmine.any( Function ) );

		expect( Autolinker.PhoneMatch ).toEqual( jasmine.any( Function ) );  // constructor function
		expect( Autolinker.PhoneMatch.name ).toBe( 'PhoneMatch' );  // function name
		expect( Autolinker.PhoneMatch.prototype.getNumber ).toEqual( jasmine.any( Function ) );

		expect( Autolinker.UrlMatch ).toEqual( jasmine.any( Function ) );  // constructor function
		expect( Autolinker.UrlMatch.name ).toBe( 'UrlMatch' );  // function name
		expect( Autolinker.UrlMatch.prototype.getUrl ).toEqual( jasmine.any( Function ) );
	} );