<commit_before>
var app = angular.module('myApp', ['onsen', 'ui.router']);

app.config(function($stateProvider, $urlRouterProvider) {

	$urlRouterProvider.otherwise("/master");

	$stateProvider
		// First page of MasterDetail
		.state('master', {
			url: '/master',
			onEnter: ['$rootScope', function($rootScope) {
				$rootScope.myTabbar.setActiveTab(0);
				$rootScope.myTabbar.loadPage('html/tab1.html');
			}]
		})
		// Second page of MasterDetail
		.state('detail', {
			parent: 'master',
			url: '/detail/:index',
			onEnter: ['$rootScope','$stateParams', function($rootScope,$stateParams) {
				$rootScope.myNavigator.pushPage('html/detail.html', {'index': $stateParams.index});
			}],
			onExit: function($rootScope) {
				$rootScope.myNavigator.popPage();
			}
		})
		.state('sliding', {
			url: '/sliding',
			onEnter: ['$rootScope', '$state', '$timeout', function($rootScope, $state, $timeout) {
					$rootScope.myTabbar.setActiveTab(1);
					$rootScope.myTabbar.loadPage('html/tab2.html');
					$timeout(function(){
						$state.go('main');
					});
			}]
		})
		.state('main', {
			parent: 'sliding',
			url: '/main',
			onEnter: ['$rootScope', function($rootScope) {
				$rootScope.myMenu.setMainPage('html/main.html', {closeMenu: true});
			}]
		})
		.state('page1', {
			parent: 'sliding',
			url: '/page1',
			onEnter: ['$rootScope', function($rootScope) {
				$rootScope.myMenu.setMainPage('html/page1.html', {closeMenu: true});
			}]
		})
		.state('page2', {
			parent: 'sliding',
			url: '/page2',
			onEnter: ['$rootScope', function($rootScope) {
				$rootScope.myMenu.setMainPage('html/page2.html', {closeMenu: true});
			}]
		})
	;

});<commit_msg>Added some comments<commit_after>
var app = angular.module('myApp', ['onsen', 'ui.router']);

app.config(function($stateProvider, $urlRouterProvider) {

	// By default show Tab 1 - MasterDetail example
	$urlRouterProvider.otherwise("/master");

	$stateProvider

		// Tab 1 - MasterDetail example - List of items
		.state('master', {
			url: '/master',
			onEnter: ['$rootScope', function($rootScope) {
				$rootScope.myTabbar.setActiveTab(0);
				$rootScope.myTabbar.loadPage('html/tab1.html');
			}]
		})

		// Tab 1 - MasterDetail example - Item details
		.state('detail', {
			parent: 'master',
			url: '/detail/:index',
			onEnter: ['$rootScope','$stateParams', function($rootScope,$stateParams) {
				$rootScope.myNavigator.pushPage('html/detail.html', {'index': $stateParams.index});
			}],
			onExit: function($rootScope) {
				$rootScope.myNavigator.popPage();
			}
		})

		// Tab 2 - SlidingMenu example - Redirects to the main page
		.state('sliding', {
			url: '/sliding',
			onEnter: ['$rootScope', '$state', '$timeout', function($rootScope, $state, $timeout) {
					$rootScope.myTabbar.setActiveTab(1);
					$rootScope.myTabbar.loadPage('html/tab2.html');
					$timeout(function(){
						$state.go('main');
					});
			}]
		})

		// Tab 2 - SlidingMenu example - Landing page
		.state('main', {
			parent: 'sliding',
			url: '/main',
			onEnter: ['$rootScope', function($rootScope) {
				$rootScope.myMenu.setMainPage('html/main.html', {closeMenu: true});
			}]
		})

		// Tab 2 - SlidingMenu example - Example page 1
		.state('page1', {
			parent: 'sliding',
			url: '/page1',
			onEnter: ['$rootScope', function($rootScope) {
				$rootScope.myMenu.setMainPage('html/page1.html', {closeMenu: true});
			}]
		})

		// Tab 2 - SlidingMenu example - Example page 2
		.state('page2', {
			parent: 'sliding',
			url: '/page2',
			onEnter: ['$rootScope', function($rootScope) {
				$rootScope.myMenu.setMainPage('html/page2.html', {closeMenu: true});
			}]
		})
	;

});
{'fraction_non_alphanumeric': 0.19813647574677995, 'fraction_numerical': 0.007947382844614962, 'mean_word_length': 3.7526041666666665, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1582290', 'n_tokens_mistral': 1491, 'n_tokens_neox': 1259, 'n_words': 217}