class Noir::JSRouteExtractor

Overview

JSRouteExtractor provides a unified interface for extracting routes from JavaScript files

Defined in:

miniparsers/js_route_extractor.cr

Class Method Summary

Class Method Detail

def self.extract_body_params(handler_body : String, endpoint : Endpoint) #

[View source]
def self.extract_cookie_params(handler_body : String, endpoint : Endpoint) #

[View source]
def self.extract_header_params(handler_body : String, endpoint : Endpoint) #

[View source]
def self.extract_params_from_context(content : String, pattern : JSRoutePattern, endpoint : Endpoint) #

[View source]
def self.extract_query_params(handler_body : String, endpoint : Endpoint) #

[View source]
def self.extract_routes(file_path : String) : Array(Endpoint) #

[View source]
def self.find_matching_brace(content : String, open_brace_idx : Int32) : Int32 | Nil #

[View source]
def self.normalize_http_method(method : String) : String #

Normalize HTTP method names to standard format


[View source]