mirror of
				https://github.com/public-transport/db-vendo-client.git
				synced 2025-11-04 01:56:33 +02:00 
			
		
		
		
	journeys: startWithWalking with default true ✨
This commit is contained in:
		
							parent
							
								
									6e60cc8bda
								
							
						
					
					
						commit
						9305a129a8
					
				
					 3 changed files with 8 additions and 2 deletions
				
			
		| 
						 | 
					@ -17,6 +17,7 @@ This version is not fully backwords-compatible. Check out [the migration guide](
 | 
				
			||||||
- ebe4fa6 `journeys()`/`journeyLeg()`: `opt.passedStations` → `opt.stopovers` 💥
 | 
					- ebe4fa6 `journeys()`/`journeyLeg()`: `opt.passedStations` → `opt.stopovers` 💥
 | 
				
			||||||
- 3e672ee `journeys()`/`journeyLeg()`: `stopover.station` → `stopover.stop` 💥
 | 
					- 3e672ee `journeys()`/`journeyLeg()`: `stopover.station` → `stopover.stop` 💥
 | 
				
			||||||
- 021ae45: `journeys()`/`journeyLeg()`: leg stopovers: parse & expose platforms
 | 
					- 021ae45: `journeys()`/`journeyLeg()`: leg stopovers: parse & expose platforms
 | 
				
			||||||
 | 
					- 85e0bdf `journeys()`: `startWithWalking` option with default `true` ✨
 | 
				
			||||||
 | 
					
 | 
				
			||||||
## `2.7.0`
 | 
					## `2.7.0`
 | 
				
			||||||
 | 
					
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -64,7 +64,9 @@ With `opt`, you can override the default options, which look like this:
 | 
				
			||||||
		regional: true
 | 
							regional: true
 | 
				
			||||||
	},
 | 
						},
 | 
				
			||||||
	tickets: false, // return tickets? only available with some profiles
 | 
						tickets: false, // return tickets? only available with some profiles
 | 
				
			||||||
	polylines: false // return a shape for each leg?
 | 
						polylines: false, // return a shape for each leg?
 | 
				
			||||||
 | 
						// Consider walking to nearby stations at the beginning of a journey?
 | 
				
			||||||
 | 
						startWithWalking: true
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
```
 | 
					```
 | 
				
			||||||
 | 
					
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
							
								
								
									
										5
									
								
								index.js
									
										
									
									
									
								
							
							
						
						
									
										5
									
								
								index.js
									
										
									
									
									
								
							| 
						 | 
					@ -97,7 +97,9 @@ const createClient = (profile, request = _request) => {
 | 
				
			||||||
			accessibility: 'none', // 'none', 'partial' or 'complete'
 | 
								accessibility: 'none', // 'none', 'partial' or 'complete'
 | 
				
			||||||
			bike: false, // only bike-friendly journeys
 | 
								bike: false, // only bike-friendly journeys
 | 
				
			||||||
			tickets: false, // return tickets?
 | 
								tickets: false, // return tickets?
 | 
				
			||||||
			polylines: false // return leg shapes?
 | 
								polylines: false, // return leg shapes?
 | 
				
			||||||
 | 
								// Consider walking to nearby stations at the beginning of a journey?
 | 
				
			||||||
 | 
								startWithWalking: true
 | 
				
			||||||
		}, opt)
 | 
							}, opt)
 | 
				
			||||||
		if (opt.via) opt.via = profile.formatLocation(profile, opt.via, 'opt.via')
 | 
							if (opt.via) opt.via = profile.formatLocation(profile, opt.via, 'opt.via')
 | 
				
			||||||
 | 
					
 | 
				
			||||||
| 
						 | 
					@ -147,6 +149,7 @@ const createClient = (profile, request = _request) => {
 | 
				
			||||||
				jnyFltrL: filters,
 | 
									jnyFltrL: filters,
 | 
				
			||||||
				getTariff: !!opt.tickets,
 | 
									getTariff: !!opt.tickets,
 | 
				
			||||||
				outFrwd,
 | 
									outFrwd,
 | 
				
			||||||
 | 
									ushrp: !!opt.startWithWalking,
 | 
				
			||||||
 | 
					
 | 
				
			||||||
				// todo: what is req.gisFltrL?
 | 
									// todo: what is req.gisFltrL?
 | 
				
			||||||
				getPT: true, // todo: what is this?
 | 
									getPT: true, // todo: what is this?
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
	Add table
		
		Reference in a new issue