Download as docx, pdf, or txt
Download as docx, pdf, or txt
You are on page 1of 7

What is stat management?

 Application state management is the process of maintaining knowledge


of an application's inputs across multiple related data flows that form a
complete business transaction -- or a session -- to understand the
condition of the app at any given moment.
 In computer science, an input is information put into the program by the
user and state refers to the condition of an application according to its
stored inputs -- saved as variables or constants.
 State can also be described as the collection of preserved information
that forms a complete session.
How State Management Works
 Overall, state management makes the state of an app visible in the form
of a data structure, improving developers' ability to work with the app.
State management libraries provide developers with the tools needed to
create the data structures and change them when new actions occur.
 There are two accepted models for state management: the front-end --
or client-side -- and back-end -- or server/application-side models.
 In front-end state management, the user's own app or browser
maintains the program's state, often by having certain buttons or user
interface features enabled or disabled and sending the state along with
the message. The user interface connection ensures the user and the
application are in harmony throughout the session.
 In back-end state management, an application component will use an
external data structure or database to record the final state when it's
done processing activities. Processing the next message will start with
retrieving the previous state from the database. The state variable in the
data structure can also synchronize the user interface -- and through it
the user -- with the state of the session.
Client side state management using cookies:

What are Cookies?

 A cookie is a piece of data that is saved in the client web browser. The
cookie is saved either in the memory of the web browser or as a text
file in the file system of the client.
 Cookies are used to identify a user, to store state information,
preferences of the user and etc. The ASP.NET use the cookies
mechanism to track users session.

How Does Cookies Mechanism Work?

 The mechanism of cookies is simple. When a client request a web


page from a server the first request isn't containing a cookie.
 The server identify that the client has no cookie and generate one.
Then the server sends the cookie to the client and from now on the
client will send the cookie in every request and the server will send
the cookie in every response.

Cookies Limitations
 Most browsers support cookies of up to 4096 bytes. This limitation
makes the cookies a way to store only small amount of data.
 Browsers have a limit on the amount of cookies a web site can save
in the client. Most browsers allow only 20 cookies per site.
 The user can set the browser to disable cookies and therefore you
can't trust cookies and you always have to check if the browser
enables cookies.
What is session?

 Session is a State Management Technique. A Session can store the value on the
Server. It can support any type of object to be stored along with our own custom
objects.
 A session is one of the best techniques for State Management because it stores the
data as client-based, in other words, the data is stored for every user separately and
the data is secured also because it is on the server.

Important properties of Session object

Session Description
Properties

CookieMode It specifies whether cookieless sessions are enabled.


Possible values are AutoDetect, UseCookies, UseDeviceProfile, and UseUri.

SessionID It provides the unique session identifier. It is secure enough and can't be decoded or hampered.
When client communicate with server, only session id is transmitted, between them.

Count It provides the number of items in Session state.

IsCookieless Provides the information whether sessions are cookieless or not.

IsNewSession It determines whether session is new or not.


IsReadOnly It determines whether the Session state is read-only.

Keys Provides the list of item names stored in Session state.

Mode It determines the current Session state store provider. Possible values are Custom,
InProc, Off, SqlServer, and StateServer.

Desktop vs mobile app :

Web framework:

 A web framework (WF) or web application framework (WAF) is a software framework that


is designed to support the development of web applications including web services, web
resources, and web APIs.
 Web frameworks provide a standard way to build and deploy web applications on the World
Wide Web. Web frameworks aim to automate the overhead associated with common
activities performed in web development.
 For example many web frameworks
provide libraries for database access, templating frameworks, and session management, and
they often promote code reuse.[1] Although they often target development of dynamic web
sites, they are also applicable to static websites.[2]

Client side web framework:


There are many frameworks out there, but currently the "big four" are considered to be the
following

Angular:

 Angular is an open-source web application framework led by the Angular Team


at Google and by a community of individuals and corporations.

 It is a complete rewrite from the same team that built AngularJS. Angular was
officially released on the 14th of September 2016.

 Angular is a component-based framework which uses declarative HTML


templates. At build time, transparently to developers, the framework's compiler
translates the templates to optimized JavaScript instructions.

Vue:

 After working on and learning from the original AngularJS project, Evan You


released Vue in 2014.

 Vue is the youngest of the big four, but has enjoyed a recent uptick in popularity.

 Vue, like AngularJS, extends HTML with some of its own code. Apart from that, it
mainly relies on modern, standard JavaScript.

React:

 Facebook released React in 2013. By this point, it had already been using React to
solve many of its problems internally. Technically, React itself is not a framework; it's a
library for rendering UI components.

 React is used in combination with other libraries to make applications — React


and React Native enable developers to make mobile applications; React
and ReactDOM enable them to make web applications, etc.

 Because React and ReactDOM are so often used together, React is colloquially
understood as a JavaScript framework.
Server side web framework:

Laravel
 Laravel is a PHP framework that makes website development faster and easier.
It is an open-source framework that has been in the works since 2011.
 Laravel makes it to the top web framework position because it quickens the go-
to-market time. The framework is based on an MVC (model-view-controller)
architecture. This ensures that the website is scalable and has increased
security.
 A unique function of the Laravel framework is the ability to implement an
authentication system. You can apply a registration, login, and password reset
form to the website. You only need is a single command for this.
 It is crucial to test a web application before you deploy it. Laravel makes the
testing process a breeze with automation testing support.
 Laravel will automatically set the configuration environment to testing. But you
can also manually set the testing environment configuration values as necessary.
Ruby On Rails
 Ruby On Rails is written in Ruby, a popular language for developing web
applications. Rails framework is open-source software that is completely free to
use. Rails has many plugins for the developers to use, which can save them time
and effort.
 The framework uses an MVC architecture. This architecture centralizes the
business logic of the application. This makes the maintenance and testing of an
application more simple. Since it is a stable framework, long-term projects can be
easily updated using Ruby on Rails
 It is very easy to make changes and manipulate code on Rails. This makes it
possible to build customized web applications with unique features.
 Ruby on Rails can reduce the time needed for web development by 20-25%. This
is because Ruby is an easy-to-use programming language, and the Rails
framework makes it even easier.
 Ruby is an object-oriented language that cuts out complexity from the
development.
Django(python):
 This is a Python web framework that is used for rapid website development.
Django is one of the best frameworks for ensuring the security of the website.
 Django uses an MVT (model-view-template) architecture. In this architecture, the
template layer separates the frontend and backend.
 Django’s design rules focus on reduced web development time. This makes it a
trustworthy framework for web development when there is a deadline to meet.
 This is a batteries-included framework model. This means the framework has a
library of ready-to-use features already installed. Users just need to import
packages that their web application needs. This model helps to reduce the time
taken to build the website.
 Website building isn’t a one-day process. Even after the application has been
deployed, administrators have to continuously work on the up-keep. Django has
a pre-made admin interface that is professional and versatile for this.

You might also like